Results 1 to 8 of 8

Thread: Runtime Error 8005

  1. #1

    Thread Starter
    Hyperactive Member
    Join Date
    Apr 2005
    Posts
    305

    Runtime Error 8005

    WHEN im trying to open a modemport with mscomm im getting the error 8005 'port already open' even though it isnt really open. the error is shown in the line

    mscomm.portopen=true

    if i proceed to the next line while debugging it tells operation valid only when port open. which means that the port isnt really open .

    what to do ??????

  2. #2
    Software Carpenter dee-u's Avatar
    Join Date
    Feb 2005
    Location
    Pinas
    Posts
    11,127

    Re: Runtime Error 8005

    Posting you code here would be of help....
    Regards,


    As a gesture of gratitude please consider rating helpful posts. c",)

    Some stuffs: Mouse Hotkey | Compress file using SQL Server! | WPF - Rounded Combobox | WPF - Notify Icon and Balloon | NetVerser - a WPF chatting system

  3. #3
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Re: Runtime Error 8005

    Quote Originally Posted by developerno1
    WHEN im trying to open a modemport with mscomm im getting the error 8005 'port already open' even though it isnt really open. [...] if i proceed to the next line while debugging it tells operation valid only when port open. which means that the port isnt really open .
    If you proceed and get the error that the operation is only valid when the port is open doesn't mean it isn't opened, it just means that your application has failed to open it. Some other application must be using the port and have it locked.

    Local ports (not IP ports since that is something different) is treated by the system as files. If you try to open a file for writing but there is a file lock on it you will fail to open it (because it's already opened). If you ignore that error and tries to write to that file you will get another error stating that the file isn't opened for writing. Same thing with the local ports on your computer.

  4. #4

    Thread Starter
    Hyperactive Member
    Join Date
    Apr 2005
    Posts
    305

    Re: Runtime Error 8005

    thanks 4 the info

  5. #5
    New Member
    Join Date
    Apr 2007
    Posts
    1

    Re: Runtime Error 8005

    Open Device Manager
    Scan for hardware changes
    Expand Mice And Other Pointing Devices
    Look for Microsoft SerialBallPoint
    If not using same, disable it.
    Reboot

  6. #6
    New Member
    Join Date
    Mar 2011
    Posts
    1

    Re: Runtime Error 8005

    i m facing error of "port already open"- "error 8005"

    so how to solve this error...

  7. #7
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Re: Runtime Error 8005

    Quote Originally Posted by manoj_vadera View Post
    i m facing error of "port already open"- "error 8005"

    so how to solve this error...
    I'm sorry but did you even bother to read this 6 year old thread before you decided to resurrect it? The question has already been answered.

  8. #8
    New Member
    Join Date
    Jul 2011
    Posts
    1

    Re: Runtime Error 8005

    Hi Joacim,

    Thanks for your time in advance, but after read this froum (and others) I still have some problems/doubts.

    Is there anyway to close the COMM1 Port that another application has opened by software (VB or other language)?

    My problem is that sometimes my program is shutting down incorrectly (I mean, not closing the port), then if I open the program again I get the famous error 8005. Within this new instance of the program I don't know how to close the port.

    Is there anyway to close the port from this new instance without shuting down the computer? Or is there any instruction (or program in any language) that allow me to close the port?

    I am using Windows 2000 Server (I am thinking change it if needed!!)

    Thanks a lot!!!

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