There is nothing that will scan the ports for a device for you. You have to write the code to attempt to open each COM port using the settings that the device expects (baud, bits, parity, stop bits, ...). If the port opens, you then try to send a command that the device expects and see if you get a correct repsonse. If so, you found it! If not, try the next port.
Dave Kreskowiak Microsoft MVP - Visual Basic