i understand how to create a socket and assign a port to a socket. But how can i make a for loop to auto assign 21 ports to it? need some helps!!!
picass0
0
Light Poster
Recommended Answers
Jump to PostYou don't. One socket, one port. On the server side you can reserve a block of ports for use by the server's clients in the hosts file. The location of that file depends on the operating system. On my computer running Vista its located here:
D:\Windows\System32\drivers\etc
All 4 Replies
Ancient Dragon
5,243
Achieved Level 70
Team Colleague
Featured Poster
picass0
0
Light Poster
Ancient Dragon
5,243
Achieved Level 70
Team Colleague
Featured Poster
picass0
0
Light Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.