Announcement

Collapse
No announcement yet.

Can HSTouch work with global variable values

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Can HSTouch work with global variable values

    Can HSTouch work with the HS.CreateVar, HS.SaveVar and HS.GetVar to display or change values in global variables? If yes, how would you configure a text item in HSTouch to display the value of a variable?

    #2
    As long as it is saved to a device code it will.
    sigpic
    A founder member of "The HA Pioneer Group" otherwise known as the "Old farts club!"

    Comment


      #3
      Originally posted by Gogs View Post
      As long as it is saved to a device code it will.
      So what you are saying is the answer is "NO", it will only work with devices, not user defined global variables.

      Comment


        #4
        Originally posted by MPodlin View Post
        So what you are saying is the answer is "NO", it will only work with devices, not user defined global variables.
        What I am saying is I do not know using what I think you are suggesting, but, I do know it will work if your variable is saved to a virtual device.

        I know, not a lot of help for what you are trying to achieve.
        sigpic
        A founder member of "The HA Pioneer Group" otherwise known as the "Old farts club!"

        Comment


          #5
          Since a text element can have a script assigned to it in the text field, you should be able to enter the following in the text field of a text element;
          [$SCRIPT=&hs.GetVar("MyVar")]

          Where MyVar is a variable you have created elsewhere via a script. I have not tried this yet, but there is no reason why it would not work....
          Harry

          Comment


            #6
            Originally posted by vossenh View Post
            Since a text element can have a script assigned to it in the text field, you should be able to enter the following in the text field of a text element;
            [$SCRIPT=&hs.GetVar("MyVar")]

            Where MyVar is a variable you have created elsewhere via a script. I have not tried this yet, but there is no reason why it would not work....
            Harry
            That worked perfectly! Thanks!!!!

            Comment

            Working...
            X