CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2003
    Posts
    2

    help plz :'( basic noob serial programming question

    Hi ppl, I was searching though the forum and can't seems to find an answer, so I decide to post my noob question:

    I wrote 2 program, 1 transmit data while the other one receive data. I bought a RS232 adaptor and solder pin 2 and 3 together so that it becomes a loop back cable to the same port (If I transmit from port 1, I should receive from port 1).

    However, when I start tranmitting on 1 program, and start the receiver program, vb always ask me to debug the following:

    1 If MSComm1.PortOpen = False Then
    2 MSComm.PortOpen = True
    3 End If

    "Error 8005: Port already open (on Line 2)

    Its confusing the **** out of me

    Thx in advance for the help ^^

    Fenix

  2. #2
    Join Date
    Jun 2002
    Location
    Cambridge, UK
    Posts
    28
    I am not a VB Guru, but in order to answer your question quickest, I suggest opening the following.
    start/run/cmd.exe, when console appears, type in MODE, a list of all devices will appear, CON, LPT, but most important of available serial ports COM1..., if not, exist the VB IDE, I have seen that if the program being debugged does not close the port, it only closes when VB exits.

    Enjoy

  3. #3
    Join Date
    Sep 2003
    Posts
    2
    Thx heaps !

    Problem solved ^^

    Fenix

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured