Raven,
I thought i would start a new thread for this topic.
Attached is a vb.net script. unzip it to your \scripts folder. You need to make a few changes:
1. change the *98 code to your code
2. Change the "1" in the SendToAlarm to the night mode sequence
3. from the hs control\Immediate Script Command window, execute the following. this will add a Night Mode btn to device 98.
You should then see the Night Mode btn.
4. Click to test.
One note about the placement of the new btn: the btn will not be vertically aligned like the existing btns. i will fix this in the next version of the plugin.
I thought i would start a new thread for this topic.
Attached is a vb.net script. unzip it to your \scripts folder. You need to make a few changes:
1. change the *98 code to your code
2. Change the "1" in the SendToAlarm to the night mode sequence
Code:
Imports HSPI_VISTAALARM rem this is what gets executed when you click the btn Sub NightMode(parms as object) Dim VA As Object VA = hs.Plugin("Vista Alarm") rem change 1 to the seq you need, this cmd assumes the first thing to send in the panel code, which will happen automatically, ie don't add your code VA.SendToAlarm("1", "Night Mode") VA = nothing End Sub rem this only need to be run once to add the button sub AddNightModeBtn(parms as object) rem change *98 to your device code hs.devicebuttonRemove ("*98", "Night Mode") hs.devicebuttonAdd("*98", "vistaalarmextras.vb(""NightMode"", """")", "Night Mode"+CHR(4)) end Sub
3. from the hs control\Immediate Script Command window, execute the following. this will add a Night Mode btn to device 98.
Code:
hs.runex "vistaalarmextras.vb" ,"AddNightModeBtn" ,""
4. Click to test.
One note about the placement of the new btn: the btn will not be vertically aligned like the existing btns. i will fix this in the next version of the plugin.
Comment