Code: Select all
[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1
OnRefreshAction=[!CommandMeasure MeasureDelayer "Execute 1"]
[Variables]
W=10000
Loc1=America/Los_Angeles
Loc2=America/Denver
DnLoc1=pacific.txt
DnLoc2=denver.txt
[MeasureDelayer]
Measure=Plugin
Plugin=ActionTimer
ActionList1=RunLoc1 | Wait #W# | RunLoc2
RunLoc1=[!EnableMeasure MsLoc1][!CommandMeasure MsLoc1 "Update"]
RunLoc2=[!EnableMeasure MsLoc2][!CommandMeasure MsLoc2 "Update"]
DynamicVariables=1
[MsLoc1]
Measure=Plugin
Plugin=WebParser
Group=Zones
url=http://api.timezonedb.com/v2/get-time-zone?key=here&format=json&by=zone&zone=#Loc1#
Disabled=1
Download=1
DownloadFile=#DnLoc1#
[MsLoc2]
Measure=Plugin
Plugin=WebParser
Group=Zones
url=http://api.timezonedb.com/v2/get-time-zone?key=here&format=json&by=zone&zone=#Loc2#
Disabled=1
Download=1
DownloadFile=#DnLoc2#
FinishAction=[!DisableMeasureGroup Zones]
[MeterDummy]
Meter=String
This should work for the "timing" you are looking for. I get back the two files, one right away and one in 10 seconds (10000 milliseconds). They are both an error message for me, with "invalid API", but that's a different issue.
So what we are doing is:
When the skin is loaded or refreshed, we kick off the ActionTimer plugin in [MeasureDelayer].
What that does is first enable the measure [MsLoc1] We don't want the WebParser measures to be updated on their own, we want them to be asleep unless we tell them to fire.
Then we force an update of [MsLoc1] to get the first download.
Then we wait 10 seconds (10000 milliseconds).
Then we enable and force update the second WebParser measure [MsLoc2].
When [MsLoc2] is "finished", it forces both WebParser measure back to sleep. One, we don't want them firing again one after the other, or we get the error you encountered. Second, the results are presumably never going to change, so what is the point of hammering the site. You just need it once.