Click here to Skip to main content
15,888,301 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hellow, I just want to know, how to view opened ports in vb.net???
If there is a source code available it will be better...
:)
Posted
Updated 8-Apr-11 17:07pm
v2
Comments
sora97 9-Apr-11 0:23am    
thanks :)

1 solution

Do you mean your local ports? You need to scan all the local ports in the set you're interested in.

Here is the code illustrating the idea:
http://social.msdn.microsoft.com/Forums/en/netfxnetcom/thread/8f0e0f22-a2d2-43f5-9909-d491297f4337[^].

Sorry if I did not understand what did you want correctly. If you need something else, feel free to correct me and clarify your Question.

[EDIT]
I almost forgot: Don't forget to limit your activity to the set of ports allowed by the regulations of IANA.
Always be compliant with this document: http://www.iana.org/assignments/port-numbers[^]. Pay attention to this statement:
The Dynamic and/or Private Ports are those from 49152 through 65535.
Good luck,
—SA
 
Share this answer
 
v3
Comments
Sergey Alexandrovich Kryukov 9-Apr-11 0:52am    
So, that was what you needed? Great.
Thanks for accepting this Answer.
Good luck.
--SA
Espen Harlinn 10-Apr-11 6:47am    
Good advice, my 5!
Sergey Alexandrovich Kryukov 10-Apr-11 20:31pm    
Thank you, Espen.
--SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900