It is currently May 2nd, 2024, 5:36 am

Getting the wrong day of the week

Get help with creating, editing & fixing problems with skins
sasyl
Posts: 3
Joined: October 26th, 2010, 6:13 pm

Getting the wrong day of the week

Post by sasyl »

Hello,

I'm new here, and this is my first try in hacking myself a Rainmeter skin..
Right now I'm trying to create a time table skin for school and Rainmeter keeps displaying the wrong day.
I keep getting the time table for Monday even though its tuesday.
I'm not really sure if its my fault or not, Here are my measures:

Code: Select all

[MeasureTime]
Measure=Time
Format=%A
DynamicVariables=1

[Sunday]
Measure=Plugin
Plugin=WebParser.dll
Url=file://#CURRENTPATH#Maarehet.txt
RegExp="(?siU).*<1>(.*)</1>.*<2>(.*)</2>.*<3>(.*)</3>"
StringIndex=1
UpdateRate=1


[Monday]
Measure=Plugin
Plugin=Plugins\WebParser.dll
URL=[Sunday]
StringIndex=2

[Tuesday]
Measure=Plugin
Plugin=Plugins\WebParser.dll
URL=[Sunday]
StringIndex=3
And the text area:

Code: Select all

[Notes]
Meter=STRING
MeasureName= [MeasureTime]
X=2
Y=32
W=186
H=#NoteHeight#
FontColor=#Color2#
FontFace=#Font#
FontSize=#Height2#
StringAlign=LEFT
StringStyle=NORMAL
AntiAlias=1
ClipString=1
DynamicVariables=1
Thanks!
User avatar
jsmorley
Developer
Posts: 22631
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Getting the wrong day of the week

Post by jsmorley »

The key MeasureName should not have brackets.

MeasureName= [MeasureTime]

Should be:

MeasureName=MeasureTime
sasyl
Posts: 3
Joined: October 26th, 2010, 6:13 pm

Re: Getting the wrong day of the week

Post by sasyl »

I thought I tried that one already, thanks! :)
User avatar
jsmorley
Developer
Posts: 22631
Joined: April 19th, 2009, 11:02 pm
Location: Fort Hunt, Virginia, USA

Re: Getting the wrong day of the week

Post by jsmorley »

sasyl wrote:I thought I tried that one already, thanks! :)
Well, no idea if this is going to solve everything, as we don't have that text file you are parsing with WebParser, so don't know if you are getting what you mean to out of that, but for sure it won't work with the brackets on MeasureName.

Good luck!
sasyl
Posts: 3
Joined: October 26th, 2010, 6:13 pm

Re: Getting the wrong day of the week

Post by sasyl »

Oh wait, now it shows only the day of the week,
I want it to output the measure named [Tuesday] and not just write Tuesday...

Everything works as it should, ie -
Everything under <1> goes in the [Sunday] Measure.. etc..

But when I use [MeasureTime] to call the measure, it calls [Monday] instead of [Tuesday] for some reason..

Here's the file I'm parsing:

Code: Select all

<1>
Sunday Stuff
</1>
<2>
Stuff I do on Monday
</2>
<3>
[8-9]Tuesday
[9-10] That's Me
[10-11]
</3>
<4>
Wednesday
</4>
<5>Etc
</5>
<6>Etc
</6>
<7>
</7>
User avatar
Alex2539
Rainmeter Sage
Posts: 642
Joined: July 19th, 2009, 5:59 am
Location: Montreal, QC, Canada

Re: Getting the wrong day of the week

Post by Alex2539 »

This won't work. Dynamic variables are not completely supported by MeasureName. You can set the initial value of MeasureName with a dynamic variable, but it will not change if that variable changes like it should. The simplest way around this is to have multiple meters, one for each day, and hide/show them when necessary.
ImageImageImageImage