The fact is that I've been reading topics and help in this forum about Variables and Conditionals for 2 days, and I can't find a way to solve and do or determine if a Dynamic Variable of the Weather Skin is EMPTY, I expose the problem:
I have a file called "Variables.inc" that contains this variable "TempCondition=0" to compare it later.
I have a file called "Measures.inc" that contains this code:
Code: Select all
;Code in file "Measures.inc"
[Variables]
@Include=#SKINSPATH#\MySkin\Resources\Variables\UserVariables.inc
@Include2=#SKINSPATH#\MySkin\Resources\Variables\Variables.inc
.
.
.
[MeasureTemperature]
Measure=WebParser
Url=[MeasureCurrentObservations]
StringIndex=6
MinValue=#TempMinValue#
MaxValue=#TempMaxValue#
IfCondition=MeasureTemperature <= #TempCondition# ;Determines if the value of MeasureTemperature is less than 0 !!! I have not been able to test this condition yet !!!
IfTrueAction=[!SetVariable LiquidColor "23,129,243"]
IfFalseAction=[!SetVariable LiquidColor "255,14,0"]
.
.
.
Code: Select all
;Code in file "Weather - Left Tab.ini"
....
[MeterTEMP]
Meter=String
MeasureName=MeasureTemperature
Meter=String
X=292
Y=42
W=350
H=50
FontSize=13.5
FontFace=#Secondary Font#
FontColor=#Secondary Font Color#
FontEffectColor=#FontEffectColor#
StringStyle=#String Style#
StringEffect=SHADOW
StringAlign=Right
AntiAlias=1
Text=%1°
....
This code together shows the value of the current Temperature of my city but does not show any value if the weather server is down or I do not have an Internet connection.
My problem is about what instructions to add to the code written in "Measures.inc" so that in case the weather server is down or I don't have an Internet connection, the Weather Skin shows me "N/A" instead of just "°"
In other words, I don't know how to check and determine if "MeasureTemperature" is empty without data and if this is the case, the Skin shows me "N/A" instead of "°"
I will be very grateful if you help me understand and write this comparison that I don't know how to do, thanks.