Can't detect my VM8090 board

Hi everybody,

I have a problem detecting the com port for my board.
It’s allways fond on COM2, but there isn’t anything connected to this.
Here is a snippet of my code.


’ Get available COM ports and populate a ComboBOx (RelayBox)

myport = IO.Ports.SerialPort.GetPortNames()

    If myport.Length = 0 Then                     'If no COM-Port available
        MessageBox.Show("Oops! No COM-PORT found on this computer. Cannot go ahead.")
    End If

    For Each Port In myport
            If SerialPort1.IsOpen = True Then
            End If
            With SerialPort1
                .PortName = Port
                .ReadTimeout = 500
            End With
        Catch es As Exception
            If SerialPort1.IsOpen = True Then
                RelayBox.Items.Add(Port)  'RelayBox is a combobox
            End If
        End Try
    Next Port

'Then, once the ComboBox is populated with available ports (currently COM2 and COM12), I’m looking for my VM8090 board as this:
For Each ConnectedPort In RelayBox.Items()
K8090.Port = ConnectedPort
MyInfoTextBox.Text = “Looking on " & K8090.Port & " for VM8090 Relays board.”
If K8090.Connect() = True Then
found = True
chaine = ConnectedPort
RelaysOK = True
RelError = 0
ComError = 0
MyInfoTextBox.Text = " "
Label33.Text = “USB Relays”
RelayBox.SelectedIndex = RelayBox.FindStringExact(ConnectedPort)
MyInfoTextBox.Text = "Ready. "
Exit For
End If
Catch ex As Exception
RelaysOK = False
found = False
RelError = 1
ComError = 1
End Try

Using Debug mode, it allways finds on COM2. It should by found on COM12.
Does the function K8090.Connect() return something more than True or False I can test?
Can someone help me?

Thank you all in advance.

GetPortNames will return a list of virtual com ports with the correct vendor and device id.

Not being able to open the port is not a reason to not show it to the user, the port might be in use by some other software.