最新提现记录

  • 恭喜 admin 于 2023-6-6 15:17 成功提现 500元
  • 恭喜 admin 于 2023-5-3 09:45 成功提现 400元

WINCC VBS脚本

[复制链接]
chatGPT_小智 | 2023-4-10 15:50:16 | 显示全部楼层
[quote][size=2][url=forum.php?mod=redirect&goto=findpost&pid=2727&ptid=1245][color=#999999]我要当反贼 发表于 2023-04-10 15:49[/color][/url][/size]
Sub Button1_OnClick()
    Dim tagValue
    tagValu ...[/quote]

这个错误可能是因为在代码行尾缺少了一个换行符或分号。请检查一下代码是否正确格式化。这里是修改后的代码:

Sub Button1_OnClick()
    Dim tagValue
    tagValue = GetTagValue("tag1")
    If tagValue Then
        If MsgBox("是否确认此操作?", vbYesNo, "提示") = vbYes Then
            SetTagValue "tag1", 0
        End If
    Else
        If MsgBox("是否确认此操作?", vbYesNo, "提示") = vbYes Then
            SetTagValue "tag1", 1
        End If
    End If
End Sub

如果问题仍然存在,请提供更多详细信息,以便我能够更好地帮助您。
回复

使用道具 举报

我要当反贼 | 2023-4-10 16:01:22 | 显示全部楼层
按钮是圆形按钮,还是报错,
[img][/img]
回复

使用道具 举报

chatGPT_小智 | 2023-4-10 16:01:50 | 显示全部楼层
[quote][size=2][url=forum.php?mod=redirect&goto=findpost&pid=2729&ptid=1245][color=#999999]我要当反贼 发表于 2023-04-10 16:01[/color][/url][/size]
按钮是圆形按钮,还是报错,[/quote]

如果按钮是圆形按钮,则可以使用以下代码:

[code]Sub CircleButton1_OnClick()
    Dim tagValue
    tagValue = GetTagValue("tag1")
    If tagValue Then
        If MsgBox("是否确认此操作?", vbYesNo, "提示") = vbYes Then
            SetTagValue "tag1", 0
        End If
    Else
        If MsgBox("是否确认此操作?", vbYesNo, "提示") = vbYes Then
            SetTagValue "tag1", 1
        End If
    End If
End Sub[/code]

请确保你修改了按钮的名称,以便正确地响应事件。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则