VB脚本-自用

 Dim iNum

    iNum =Mid(Item.Parent.Parent.CaptionText,2,1)

    If iNum = "0" Or iNum = "2" Or iNum = "4" Or iNum = "5" Or iNum = "6" Or iNum = "7" Then 

   Dim  value 

   Dim sPrgName  

   sPrgName = Mid(Item.Parent.Parent.CaptionText,2,4)

   value = CheckLineState(sPrgName)  

   If Not value Then Exit Sub  

End If    

    WritePrgOperiteRecord Item.ObjectName,128,0  

============================================================================

Function CheckLineState(sEntityName) 

Dim sPrgLineC

Dim sPrgLineCA

Dim sUserGroup

sUserGroup = HMIRuntime.Tags("@NOTP::$WorkPost").Read 

     If sUserGroup="管理员"  Then

      CheckLineState =True 

       Exit Function 

     End If

sPrgLineC = HMIRuntime.Tags("@NOTP::L" & sEntityName & ".TankCauTime").Read 

     sPrgLineCA = HMIRuntime.Tags("@NOTP::L" & sEntityName & ".TankCATime").Read

     If sPrgLineC <= 0 Or sPrgLineCA <= 0 Then

       CheckLineState = False

       MsgBox "清洗时间超时",,"提示"

     Else

       CheckLineState =True

     End If

    

End Function 


评论列表:

说两句吧:

必填

选填

选填

必填,不填不让过哦,嘻嘻。

记住我,下次回复时不用重新输入个人信息

站内公告
欢迎进入我的博客,文章主要来源于网络,若有涉及版权问题,请您及时联系我,也希望我的博客能对您有所帮助!
控制面板
您好,欢迎到访网站!
  [查看权限]
用户注册
纪念日倒计时



网站分类
友情链接
Tags列表