currentpb2 value is 16 for the following example
CustomScriptButton ID is also 16
The following code works as expected:
- Code: Select all
if currentpb2 = 16
{
WDCustomScriptTint,currentpb2,0,0,255
}
else
{
WDCustomScriptTint,currentpb2,0,255,0
}
It colors the button blue, because currentpb2 is 16
The following code does not work:
- Code: Select all
if currentpb2 = MyID
{
WDCustomScriptTint,currentpb2,0,0,255
}
else
{
WDCustomScriptTint,currentpb2,0,255,0
}
It colors the button green even though MyID should return 16 as the button ID is 16. Considering currentpb2 is also 16 I was expecting the button to turn blue.
Also, if I include MyID in a loop it takes on a bunch of value as the loop runs even though the button launching the script is ID 16.
Thanks for the help!
regards