Getting error about port COM11
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Getting error about port COM11
Recently a portion of my code which uses port COM11 to simulate a scanning barcode feature has stopped working, giving me an error as follows:
System.UnauthorizedAccessException: Access to the port 'COM11' is denied
This is the code in question, it has always worked for years before I even got the project and now suddenly it doesn't. I have tried rebooting the machine, changing the com port, trying different ports, all giving the same error as above.
Dim SerialPort, Port, BaudRate, Parity, DataBits, StopBits
Port = "COM11"
BaudRate = 9600
Parity = None
DataBits = 8
StopBits = 1
Call Delay(1000)
Set SerialPort = dotNet.System_IO_Ports.SerialPort.zctor(Port, BaudRate, Parity, DataBits, StopBits)
SerialPort.Open
SerialPort.Write PLU & Chr(13)
SerialPort.Close
- Labels:
-
Desktop Testing
-
Test Run
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I suggest contacting Support about this directly. Here's the link:
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
> Parity = None
What is the value for None? Can't it be the root of the problem?
/Alex [Community Champion]
____
[Community Champions] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Champions]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Champion] signature is assigned on quarterly basis and is used with permission by SmartBear Software.
https://community.smartbear.com/t5/Community-Champions/About-the-Community-Champions-Program/gpm-p/252662
================================
