Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load AxMSComm1.PortOpen = True If Err.Number = 0 Then MsgBox("Open communication!") Else MsgBox("Error opening COM port. Please verify MSR is set to COM Port 3.") End If Exit Sub RegError: MsgBox("Error locating ODBC connection. Please verify ODBC connection has been created.") End End Sub Private Sub AxMSComm1_OnComm(ByVal sender As Object, ByVal e As System.EventArgs) Handles AxMSComm1.OnComm Dim InBuffer As String Select Case AxMSComm1.CommEvent Case MSCommLib.OnCommConstants.comEvReceive InBuffer = CStr(AxMSComm1.Input) Call HandleInput(InBuffer) End Select End Sub Sub HandleInput(ByVal InBuffer As String) ' This is where you will process your input. This ' includes trapping characters, parsing strings, ' separating data fields, etc. For this case, you ' are simply going to display the data in the TextBox. txtOCR.Text = InBuffer MsgBox(InBuffer) End Sub
Join the community of 500,000 technology professionals and ask your questions.