Page 1 of 1

check on changed uservariable

Posted: Monday 09 December 2024 15:46
by manjh
For a changed deviced, there is a special table (devicechanged).
Is there something similar for a changed uservariable?

Re: check on changed uservariable

Posted: Monday 09 December 2024 16:22
by waltervl

Re: check on changed uservariable

Posted: Monday 09 December 2024 17:22
by manjh
I used that in:

Code: Select all

for variableName,variableValue in pairs(uservariablechanged) do

But I am looking for a specific variable, so would like to do:

Code: Select all

if uservariablechanged["NFCvalue"] then

Unfortunately that does not work.

It's not a big deal, chances are there will not be more than onevariable changing at any one time, so I would be running through a table of one anyway.
Guess I'll stick to the first method.