The port has been opened by third-party serial application before your program calls Attach method.
Sub OnOpenBeforeAttach(pid As Long, Path As String)
|Visual C++ (MFC)||
void OnOpenBeforeAttach(LONG pid, LPCTSTR Path);
PID of the application opened the port.
Full path to the application opened the port.