Announcement

Collapse
No announcement yet.

hs.WriteLog error - Class doesn't support automation - Solution!

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    hs.WriteLog error - Class doesn't support automation - Solution!

    Getting the error message shown below when trying to run a script that has

    Code:
    hs.WriteLog "irr",zone
    where zone is variable defined in the script. Tried to put ( ) around the parameters but got compile error

    Code:
    hs.WriteLog ("irr",zone)
    Error message in HS4 log

    Code:
    Running script, script run or compile error in file: Stop Irrigation all zones.txt430:Class doesn't support Automation: 'hs.WriteLog' in line 41 More info: Class doesn't support Automation: 'hs.WriteLog'

    #2
    Try:

    Code:
    hs.writelogex "irr", zone

    There is also an optional color code in HS4 you can specify as hex.
    Code:
    hs.writelogex "irr", zone, "#008080"
    Will output your line in a nice groovy Teal!

    Comment


      #3
      George

      Thanks a lot. This worked and the color is lovely. You're an artist man :-)

      Comment


        #4
        😎😎😎😎

        My pleasure! Love picking colors for different functions so the eye is drawn to what you are looking for without having to read the From field

        BTW, there is a free color picker right here on this board.
        • Start a reply or a new post that you don't intend to his Post or Save on
        • Then drop down the A with the down arrow next to the size button in the editing controls.
        • Then select "More Colors..." at the bottom of the drop-down.
        • Then just move your mouse around the color fields, the hex color associated with where your mouse is and the color shown in the Highlight box is the hex you enter in the writelogex command.
        Enjoy!

        Comment

        Working...
        X