serial port

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • ST

    serial port

    I want my program to show the number and name of the serial ports on my
    computer in the same style at e.g. Hyperterminal. Like,,,if the computer has
    2 serial ports there will only be 2 serial ports on the list,,,or 10 if the
    computer has 10.

    Any suggestions on how this can be done ?


  • jamie

    #2
    Re: serial port

    ST wrote:[color=blue]
    > I want my program to show the number and name of the serial ports on my
    > computer in the same style at e.g. Hyperterminal. Like,,,if the computer has
    > 2 serial ports there will only be 2 serial ports on the list,,,or 10 if the
    > computer has 10.
    >
    > Any suggestions on how this can be done ?
    >
    >[/color]

    The current ports are listed in the registry:
    HKEY_LOCAL_MACH INE/HARDWARE/DEVICEMAP/SERIALCOMM (on winXP)

    Reading from here works well because this list is dynamically created
    (i.e. if a virtual serial port is created via USB)

    Hope this helps,

    Jamie

    Comment

    • ST

      #3
      Re: serial port

      I'm sure it does, thanks.

      "jamie" <jamie@noway.co m> wrote in message
      news:jYoVc.2550 1$ZI1.1067692@n ews20.bellgloba l.com...[color=blue]
      > ST wrote:[color=green]
      > > I want my program to show the number and name of the serial ports on my
      > > computer in the same style at e.g. Hyperterminal. Like,,,if the computer[/color][/color]
      has[color=blue][color=green]
      > > 2 serial ports there will only be 2 serial ports on the list,,,or 10 if[/color][/color]
      the[color=blue][color=green]
      > > computer has 10.
      > >
      > > Any suggestions on how this can be done ?
      > >
      > >[/color]
      >
      > The current ports are listed in the registry:
      > HKEY_LOCAL_MACH INE/HARDWARE/DEVICEMAP/SERIALCOMM (on winXP)
      >
      > Reading from here works well because this list is dynamically created
      > (i.e. if a virtual serial port is created via USB)
      >
      > Hope this helps,
      >
      > Jamie[/color]


      Comment

      • Randy Birch

        #4
        Re: serial port

        like this? ... http://vbnet.mvps.org/code/system/comtestmscomm.htm or
        VBnet provides Intermediate and Advanced Win32 API code for VB developers. Comprehensive Code, FAQ, Developers Resources & News, alphabetical API/Type/Constant/Method Index, along with the largest Visual Basic-related links list on the net.


        --

        Randy Birch
        MVP Visual Basic

        Please respond only to the newsgroups so all can benefit.


        "ST" <Not@valid.co m> wrote in message
        news:4125eb62$0 $284$edfadb0f@d read16.news.tel e.dk...
        :I want my program to show the number and name of the serial ports on my
        : computer in the same style at e.g. Hyperterminal. Like,,,if the computer
        has
        : 2 serial ports there will only be 2 serial ports on the list,,,or 10 if
        the
        : computer has 10.
        :
        : Any suggestions on how this can be done ?
        :
        :

        Comment

        • ST

          #5
          Re: serial port

          What this code does, is giving me the active ports on the computer. Not the
          amount of installed ports on the computer.


          "Randy Birch" <rgb_removethis @mvps.org> wrote in message
          news:ArvVc.1830 908$Ar.652247@t wister01.bloor. is.net.cable.ro gers.com...[color=blue]
          > like this? ... http://vbnet.mvps.org/code/system/comtestmscomm.htm or
          > http://vbnet.mvps.org/code/system/comtestapi.htm
          >
          > --
          >
          > Randy Birch
          > MVP Visual Basic
          > http://vbnet.mvps.org/
          > Please respond only to the newsgroups so all can benefit.
          >
          >
          > "ST" <Not@valid.co m> wrote in message
          > news:4125eb62$0 $284$edfadb0f@d read16.news.tel e.dk...
          > :I want my program to show the number and name of the serial ports on my
          > : computer in the same style at e.g. Hyperterminal. Like,,,if the computer
          > has
          > : 2 serial ports there will only be 2 serial ports on the list,,,or 10 if
          > the
          > : computer has 10.
          > :
          > : Any suggestions on how this can be done ?
          > :
          > :
          >[/color]


          Comment

          • Randy Birch

            #6
            Re: serial port

            Then you want this ... http://vbnet.mvps.org/code/enums/enumports.htm

            --

            Randy Birch
            MVP Visual Basic

            Please respond only to the newsgroups so all can benefit.


            "ST" <ST@notvalid.dk > wrote in message
            news:412878e8$0 $314$edfadb0f@d read16.news.tel e.dk...
            : What this code does, is giving me the active ports on the computer. Not
            the
            : amount of installed ports on the computer.
            :
            :
            : "Randy Birch" <rgb_removethis @mvps.org> wrote in message
            : news:ArvVc.1830 908$Ar.652247@t wister01.bloor. is.net.cable.ro gers.com...
            : > like this? ... http://vbnet.mvps.org/code/system/comtestmscomm.htm or
            : > http://vbnet.mvps.org/code/system/comtestapi.htm
            : >
            : > --
            : >
            : > Randy Birch
            : > MVP Visual Basic
            : > http://vbnet.mvps.org/
            : > Please respond only to the newsgroups so all can benefit.
            : >
            : >
            : > "ST" <Not@valid.co m> wrote in message
            : > news:4125eb62$0 $284$edfadb0f@d read16.news.tel e.dk...
            : > :I want my program to show the number and name of the serial ports on my
            : > : computer in the same style at e.g. Hyperterminal. Like,,,if the
            computer
            : > has
            : > : 2 serial ports there will only be 2 serial ports on the list,,,or 10
            if
            : > the
            : > : computer has 10.
            : > :
            : > : Any suggestions on how this can be done ?
            : > :
            : > :
            : >
            :
            :

            Comment

            Working...