Global Script Problem
George Handley
ghandley at kc.rr.com
Mon Jun 15 11:52:39 EDT 2015
XTensioneers,
I’m having problems getting what I thought was a simple script working. The script takes some cryptic text (ft) held as a property of “Davis Forecast text” that the Davis WeatherVue spits out, and converts it to a more understandable text for playback on demand.
I originally built the extensive code in Pages, and tried to copy and paste it into a new XTension global script, but I couldn’t save it.
I thought perhaps Pages was creating an rtf text file, so I copy and pasted it in Notes to make sure it wasn’t, but that didn’t work either. It’s going to be a long script, but I can’t even get started. Here is just the first part. I had to comment out the first case as XTension doesn’t like it.
-- Global script Davis Translate Forecast
ft = ((Get Unit Property "Forecast Text" from unit "Davis Forecast Text") as string)
--if ft = "The forecast is Mostly Cloudy And Cooler. Precipitation Likely. Windy With Possible Wind Shift To The W, Nw, Or N.” then
--ft = "The forecast is Mostly Cloudy And Cooler. Precipitation Likely. Windy With Possible Wind Shift To The West, Northwest, Or North.”
--Set Unit Property "Forecast Text" to ft in unit "Davis Forecast Text"
--end if
Does anyone see anything obvious for why I can’t compile the above?
Thanks,
George
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://shed.com/pipermail/xtensionlist/attachments/20150615/66143ae3/attachment.html>
More information about the XTensionList
mailing list