Hi. im a newbie in vb6 i need to receive data using mscomm in vb 6...
here is my code but it doesnt work,
please help me...
thanks in advance GODBLESS
---------------------------
even that i declare that the portopen = true it appears that it is close...
here is my code but it doesnt work,
please help me...
thanks in advance GODBLESS
---------------------------
Code:
Private Sub Form_Load()
On Error Resume Next
' Fire Rx Event Every Two Bytes
MSComm1.RThreshold = 2
' When Inputting Data, Input 2 Bytes at a time
MSComm1.InputLen = 2
' 9600 Baud, No Parity, 8 Data Bits, 1 Stop Bit
MSComm1.Settings = "9600,n,8,1"
' Make sure DTR line is low to prevent Stamp reset
MSComm1.DTREnable = False
' Open COM21
MSComm1.CommPort = 21
MSComm1.PortOpen = True
End Sub