以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  这段语句为何不能正确执行?  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=33581)

--  作者:lhls1688
--  发布时间:2013/5/21 11:04:00
--  这段语句为何不能正确执行?

If not Tables("机构信息表.员工信息表").Current("员工状态")  Like ("\'*正常*\'") Then
    MessageBox.Show("改变员工状态请在备注中说明改变原因","提示",MessageBoxButtons.OK,MessageBoxIcon.Information)
    Tables("机构信息表.员工信息表").Current("备注")=  Tables("机构信息表.员工信息表").Current("备注")&chr(10)&"原因说明:"
    Forms("员工备注").Open()
    Tables("机构信息表.员工信息表").current.Locked=True
    Tables("机构信息表.员工信息表").Current("机构码") = "0000"
Else
    MessageBox.Show("状态正常的员工不允许删除,请核查!","注意",MessageBoxButtons.OK,MessageBoxIcon.Warning)
    Return
End If

当点击正常时,程序流程依旧执行then下的语句,这是何故?


--  作者:Bin
--  发布时间:2013/5/21 11:06:00
--  
If not Tables("机构信息表.员工信息表").Current("员工状态")  Like "*正常*" Then