Announcement

Collapse
No announcement yet.

XML Weather From NOAA.gov [VB]

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

    XML Weather From NOAA.gov [VB]

    This VB script uses the same NOAA XML information as the asp page in the previous post. However this is a VB script that will update 14 HS devices with a variety of weather information.

    This script will automatically create 14 devices on the House code, and Unit codes of your choice. This is configured at the top of the script, as well as setting the location for the information to retreive. You can also set the information to be stored in Farenheit, Celcius, or both.

    Full documentation is included in the sctipt. The NOAA site appears to be very fast and reliable. Testing on my system, connected with DSL, has shown the devices to update when the script is called in less that one second!

    Again, it is good to mention that this information is made freely available from NOAA, and is listed as "Public Domain" in the disclaimer on NOAA's site.

    After the information is stored in a device, it is actually VERY easy to incorporate it into your own .asp pages. For example, you have a HS device that has the current temperature stored in "W32". To pull this information into your own custompage, simply use the following line:
    Code:
    The Temperature is: <%= Response.Write (hs.DeviceString("w32"))%>
    Also note, if you are inserting this code into an existing htm/html page, when the code is inserted, you will need to save the page with the .asp extension. This tells HS an your browser to execute the code, and not just display it in an html page as text.

    The discussion for this script is located HERE
    Attached Files
    Last edited by johnwpb; November 20, 2004, 01:06 AM.
    Visit My Home Seer Site at:
    www.JohnWPB.com
    Created with LCARS
Working...
X