I installed a device on my computer (for example a cardreader). I ran this code but the ComboBox
was not filled.
Code:
using System.Management;
using System.IO.Ports;
foreach (string portname in SerialPort.GetPortNames())
{
comboBox1.Items.Add(portname);
}
Since this didn't work, how can I see the port addresses and properties of the devices installed on the computer?