Click here to Skip to main content
15,843,142 members
Please Sign up or sign in to vote.
5.00/5 (1 vote)
See more:
Hi there,

I wanted to make an application to detect Serial Ports and retrieve the device names of the Emulated ones. This is because in w7 device manager the emulated COM ports dont show their number and when i use several devices gets kind of messy to configure all of them in another app.
Any idea?
Thanks in advance...
Posted
Comments
Dalek Dave 24-Jul-10 15:54pm    
Reason for my vote of 5
Good Question

You can enumerate the available serial Port names using the following code;

VB.NET
For Each item As String In My.Computer.Ports.SerialPortNames
    Debug.Print(item)
Next
 
Share this answer
 
Comments
Dalek Dave 24-Jul-10 15:55pm    
Good Answer.
Dim s1 As String
For Each s1 In SerialPort.GetPortNames()
    msgbox(s1)
Next s1
 
Share this answer
 

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