Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Function SetVars(s)
Set v = ActiveDocument.Variables(s & "_v")
If v.GetContent.String = "1" Then
v.SetContent "0", true
Else
v.SetContent "1", true
End If
End Function
If the requirement is to toggle the variable value between 1 and 0, you may implement using a button with action. There is no need for a VB macro. An example is attached.
Thats perfect!
Thanks!!!