im looking already for weeks to input data to a machine via com1,
problem i find no solution, the command to write to the port is WT and carriage return, then i should get a value from the
machine displayed in a cell but my programm hangs everytime and don't see what's wrong, can someone help me please ?
would be very thanksfull. Tou can find the code here:
Dim strInput As Long Private Sub CommandButton1_Click() Open "COM1:9600,N,8,1" For Output As #1 cmnd$ = "WT" cmnd$ = cmnd$ + Chr$(13) Print #1, cmnd$ Close #1 Open "COM1: 9600,N,8,1" For Input As #1 Input #1, strInput ActiveCell.Offset(rowOffset:=0, columnOffset:=1).Activate ActiveCell = strInput Close #1 End Sub