'变更schedule,将工序信息写入下方表中
MessageBox.Show(1)
‘调试提示1’
If Not DataTables.Contains("WorkOrderStatus") Then
DataTables.Load("WorkOrderStatus")
End If
Dim wo As String
Dim r As Row = Tables("Schedule").Current
MessageBox.Show("2")
‘调试提示2’
If r IsNot Nothing Then
wo = r("WO")
Tables("CellKanban_Table2").Filter = "[wo]='" & wo & "'"
Else
Return
End If
If Not DataTables.Contains("Production_List") Then
DataTables.Load("Production_List")
End If
If wo Is Nothing Then GoTo 1
Tables("CellKanban_Table3").Filter = "WOID = '" & wo & "'"
Tables("CellKanban_Table3").sort = "OPSeq,CLOCKIN"
Dim PN As String = e.Table.Current("PartID")
Dim Pbx As WinForm.PictureBox = e.Form.Controls("PictureBox1")
Dim fpf As String
Dim fp As String = "P:\General documents\Setup\Pic\" '\\freenas01chi\Production\General documents\Setup\Pic\
fpf = fp & PN & ".jpg"
If FileSys.FileExists(fpf) = False Then
fp = "T:\ME\ME Documentation\Picture\" '\\domain.pragon\china\ME\ME Documentation\Picture\" & PN & ".jpg"
fpf = fp & PN & ".jpg"
If FileSys.FileExists(fpf) = False Then
fpf = "P:\General documents\Setup\Pic\Error.jpg"
End If
End If
pbx.ImageFile = fpf
pbx.SizeMode = ImageSizeMode.Zoom
1:
奇怪的是,如果存在工单号则提示、运行均正常,一旦点击空行,则连 调试提示1、2均不出现。更别说运行下面的数据了。 此外还有一个情况,点击存在数据行后,调试提示均出现2次。