John,
Are you using a serial comm component of some type? Does it have a method
for opening a COM port? I'm using an old C++ Builder shareware component
called ZComm (still available), and I use a brute-force method to make a
list of available COM ports, as outlined below. Note that the resulting list
will not contain COM ports that exist but are already in use.
Joe
for (int i=1; i<=256; i++)
{
if (open_com(i) == true)
{
add i to list
close_com(i)
}
}
"John" wrote in message
news:4766f9fb$1@newsgroups.borland.com...
> How can I scan for all available serial com ports?
>
> Thanks,
> John
>
>
|