This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm that you accept these cookies being set.

changing the state of the button to switch the widget
#7
You will need to attach an event script to the control object (0/1/24) and create two status objects for plus/minus (32/1/13 and 32/1/14 in this example, change as needed). Then you need to attach status objects to the plus/minus buttons.

Event script:
Code:
stat_1 = '32/1/14'
stat_0 = '32/1/13'

if event.getvalue() then
  stat_c = stat_1
  stat_i = stat_0
else
  stat_c = stat_0
  stat_i = stat_1
end

-- toggle status
grp.write(stat_c, not grp.getvalue(stat_c))
-- turn off opposite status
grp.write(stat_i, false)
Reply


Messages In This Thread
RE: changing the state of the button to switch the widget - by admin - 20.08.2021, 10:08

Forum Jump: