Public Function WO_Logged_In(ByVal terminal As Long, ByVal data As String)
'check internal table to see if the Workorder is logged in
Dim X As String, Y As String
Call Sorter("Internal", "E2", "E:E")
X = Do_Lookup("Internal", TerminalDataRecord(terminal).TermDataSet(60), "E:F", 2)
Select Case X
Case X = ""
WO_Logged_In = 0 'available for log in to a station
Case X = TerminalDataRecord(terminal).TermDataSet(60)
WO_Logged_In = 1 'logged into scanned station
Case X <> TerminalDataRecord(terminal).TermDataSet(60)
WO_Logged_In = 2 'logged into a different station then scanned
End Select
End Function
|