I've made a widget that is supposed to tell me what % of my shift is complete, but it's not auto-refreshing so if I want the current value I have to manually refresh the skin. How can I make it auto-refresh?
I've tried setting the Update= manually, adding OnUpdateAction and [!Redraw] and a bunch of other things that I regrettably didn't save since they didn't work so now I can't remember them. (Code below has left out metadata, xy coordinates, and irrelevant variables and values not pertaining to this question such as font settings.)
[Rainmeter]
MiddleMouseDownAction=[!WriteKeyValue Variables OffWorkTime1 #OffWorkTime2#][!WriteKeyValue Variables OffWorkTime2 #OffWorkTime3#][!WriteKeyValue Variables OffWorkTime3 #OffWorkTime4#][!WriteKeyValue Variables OffWorkTime4 #OffWorkTime5#][!WriteKeyValue Variables OffWorkTime5 #OffWorkTime1#][!Refresh]
OnUpdateAction=[!UpdateMeasure MeasurePercElaps][!UpdateMeter MeterPercentDisplay][!WriteKeyValue Variables OffWorkTime1 #OffWorkTime1#][!WriteKeyValue Variables OffWorkTime2 #OffWorkTime2#][!WriteKeyValue Variables OffWorkTime3 #OffWorkTime3#][!WriteKeyValue Variables OffWorkTime4 #OffWorkTime4#][!WriteKeyValue Variables OffWorkTime5 #OffWorkTime5#][!Redraw]
LeftMouseDownAction=[!UpdateMeasure MeasurePercElaps][!UpdateMeter MeterPercentDisplay][!Redraw]
Update=200
[Variables]
OffWorkTime1=870
OffWorkTime2=900
OffWorkTime3=990
OffWorkTime4=1140
OffWorkTime5=1260
HR=[MeasureHour]
MN=[MeasureMin]
PElaps=[MeasurePercElaps:0%]
;MEASURES===================
[MeasureHour]
measure=time
format=%H
[MeasureMin]
measure=time
format=%M
[MeasurePercElaps]
measure=calc
formula=(((540 - (#OffWorkTime1# - ((#HR# * 60) + #MN#))) / 540) * 100)
MinValue=0
MaxValue=100
;METERS===================
[MeterBarPercent]
meter=bar
MeasureName=MeasurePercElaps
W=201
h=23
ValueRemainder=100
BarColor=84,165,196,255
BarOrientation=Horizontal
DynamicVariables=1
[MeterPercentDisplay]
meter=string
MeasureName=MeasurePercElaps
AntiAlias=1
NumOfDecimals=1
DynamicVariables=1
Postfix=% COMPLETE
It should be auto-refreshing every Update cycle, but instead the only way I can get it to refresh the values displayed is by manually refreshing it. It gives the correct value when refreshed, so I know the formulas aren't faulty, but it's just not updating automatically for some reason. The LeftMouseDownAction= thing I put in there doesn't work either. Any pointers you have would be much appreciated.
~δelta