Results 1 to 2 of 2
- 07-02-2010, 09:04 AM #1
Senior Member
- Join Date
- Jan 2010
- Posts
- 138
- Rep Power
- 0
Socket and how to launch thread for receiving socket messages
Hello All,
I am new to Java and I am writing socket programming, how to launch thread for receiving message?
please help
thanks & regards
newbiejava
Java Code:import java.util.StringTokenizer; import java.net.Socket; StringTokenizer st = new StringTokenizer(this.jTextField1.getText(),":"); String ip = st.nextToken(); int port = Integer.parseInt(st.nextToken()); try { socket = new Socket(ip, port); } catch (UnknownHostException ex) { } catch (IOException ex) { }
- 07-02-2010, 01:18 PM #2
Similar Threads
-
Receiving data from a socket and querying database
By cotarelo in forum JDBCReplies: 7Last Post: 06-22-2010, 10:49 AM -
Byte Array sending and receiving using Socket
By venkateshcoolmoon in forum NetworkingReplies: 3Last Post: 01-23-2010, 07:34 PM -
best way to signal a thread that's blocking on a socket receive
By danieru in forum Threads and SynchronizationReplies: 5Last Post: 09-08-2009, 04:47 PM -
append response to the request from Socket and write to another socket
By vaibhav_singh_vs@yahoo.co in forum NetworkingReplies: 3Last Post: 04-17-2009, 07:02 PM -
Receiving Text over a Socket (ReadLine() problem)
By HermanHope in forum New To JavaReplies: 1Last Post: 04-09-2009, 10:35 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks