I have found some examples and made what I thought was the changes I need. But when the script runs I get the following error:
Running script, script run or compile error in file: C:/Program Files/HomeSeer HS3/scripts/Weather_Read.txt430:Class doesn't support Automation: 'hs.setdevicestring' in line 13 More info: Class doesn't support Automation: 'hs.setdevicestring'
Here is the script:
Sub Main()
Dim description, temperF
Set xmlDoc = CreateObject("Msxml2.DOMDocument")
xmldoc.async = False
xmlDoc.load("http://api.wunderground.com/weatherstation/WXCurrentObXML.asp?ID=KNCINDIA5")
Set ElemList = xmlDoc.getElementsByTagName("temp_f")
temperF = ElemList.item(0).getAttribute("data")
hs.setdevicestring "w100", "Outside Temperature: " & temperF & chr(176) & "F", True
hs.setdevicevalue "w100", Cint(temperF)
End Sub
Running script, script run or compile error in file: C:/Program Files/HomeSeer HS3/scripts/Weather_Read.txt430:Class doesn't support Automation: 'hs.setdevicestring' in line 13 More info: Class doesn't support Automation: 'hs.setdevicestring'
Here is the script:
Sub Main()
Dim description, temperF
Set xmlDoc = CreateObject("Msxml2.DOMDocument")
xmldoc.async = False
xmlDoc.load("http://api.wunderground.com/weatherstation/WXCurrentObXML.asp?ID=KNCINDIA5")
Set ElemList = xmlDoc.getElementsByTagName("temp_f")
temperF = ElemList.item(0).getAttribute("data")
hs.setdevicestring "w100", "Outside Temperature: " & temperF & chr(176) & "F", True
hs.setdevicevalue "w100", Cint(temperF)
End Sub
Comment