Re: One Client application is assigned one port number.
Hi.
If you know TCP/IP, you can understand your problem.
However, this is my guess.
If we open Internet application, client application will be assigned the port
number from OS. On the other hand, Server is assigned a well known port.
Server side TCP or UDP deals with (Source IP address, well known port). This
means that one server can be access many client by same port becasue
TCP or UDP figure it out by combination of Source IP address and port #.
However, at client side, one applicaton will be assigned some port #. If
we open the same application, OS assigns the other port #.
If you use the same application by another thread, this must be not controled
because thread generates process of application.
That is, process must be done by its each port number. If you generate thread
in order to generate process, it must be conflict.
Hope for help.
-Masaaki Onishi-
Re: One Client application is assigned one port number.
Hi,
thanx for ur suggestions.I don't think it is a problem with the port numbers as FTP does occur, but in a corrupted fashion (interestingly, the first 9140 bytes are lost somewhere !!!). The following is the method of connection that I adopted in the application that uses the FTP classes. I first want an FTP to be done from the application client program to the server program. So, I try to start the FTP server in the application server program at a certain port number and if I fail, I keep incrementing the portnumber and keep on trying untill I succeed. This starting of the FTPServer is also done in a separate thread. Then I send across the port number on which the FTP server is started to the client program. Now the client application program starts an FTPClient class (in a new thread), connecting to the well known FTP server port number (got from the server program) on the machine running the server application program.
regards and thanx,
JAIKISH