1) Break up the date into its separate components using the RegExp, then you can pass those string numbers (year, month, day) through Measure=Calc measures to convert them to numbers you can use as you see fit. See my example below
2) You only have to repeat the RegExp pattern as many times as you like to get repeated iterations of what you are capturing. There is no "loop" in Rainmeter that could be used to do this, you do it with the RegExp itself. In my example below, I showed how you would use a "look ahead assertion" in Regular Expression to get as many iterations as you want, without failing if there are in fact fewer in the source than you are asking for.
3) Pulling the links out of the "text" will take some doing. I did not put it in my example below, but you would probably have to do two full parses of the source using WebParser. The first to get everything in my example below, then a second pass through with a whole new RegExp to pull the links out of the text, again using a "look ahead assertion" to ensure it doesn't fail if there isn't a link in a particular entry. There may be (and probably is) a way to get them in the first pass, by changing the main RegExp to have embedded look ahead assertions looking for links inside the capture for the "text", but that is beyond my current Regular Expression skills, and I had a small stroke just thinking about it...
This is based on your XML file, but not on your skin as such. Poke around with this and see what I am doing, and it should give you some help to see how to use the approaches in your own skin.
Code: Select all
[Rainmeter]
Update=1000
DynamicWindowSize=1
[Variables]
FontName=Trebuchet MS
URL="file://#CURRENTPATH#Test.xml"
Get=(?(?=.*<row eventID=".*").*<row eventID=".*eventDate="(\d\d\d\d)-(\d\d)-(\d\d).*".*eventTitle="(.*)".*duration="(.*)".*eventText="(.*)")
[FontStyle]
FontFace=Trebuchet MS
FontColor=255,255,255,255
FontSize=11
StringStyle=Bold
AntiAlias=1
[Source]
Measure=Plugin
Plugin=Plugins\WebParser.dll
UpdateRate=1800
Url=#URL#
RegExp="(?siU)#Get##Get##Get#"
[MeasureYear1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=1
[MeasureMonth1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=2
[MeasureDay1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=3
[MeasureTitle1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=4
[MeasureDuration1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=5
[MeasureText1]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=6
Substitute="
":" ",">":">","<":"<","&":"&",""":""","&Quot;":"","<a href=":"","</a>":"""
[MeasureYear2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=7
[MeasureMonth2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=8
[MeasureDay2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=9
[MeasureTitle2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=10
[MeasureDuration2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=11
[MeasureText2]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=12
Substitute="
":" ",">":"","<":"","&":"&",""":" ","&Quot;":" ","a href=":"","/a":"""
[MeasureYear3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=13
[MeasureMonth3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=14
[MeasureDay3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=15
[MeasureTitle3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=16
[MeasureDuration3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=17
[MeasureText3]
Measure=Plugin
Plugin=Plugins\WebParser.dll
Url=[Source]
StringIndex=18
Substitute="
":" ",">":">","<":"<","&":"&",""":""","&Quot;":"","<a href=":"","</a>":"""
[MeasureYear1Num]
Measure=Calc
Formula=MeasureYear1
Substitut=".0000":""
[MeasureMonth1Num]
Measure=Calc
Formula=MeasureMonth1
Substitut=".0000":""
[MeasureDay1Num]
Measure=Calc
Formula=MeasureDay1
Substitut=".0000":""
[MeasureYear2Num]
Measure=Calc
Formula=MeasureYear2
Substitut=".0000":""
[MeasureMonth2Num]
Measure=Calc
Formula=MeasureMonth2
Substitut=".0000":""
[MeasureDay2Num]
Measure=Calc
Formula=MeasureDay2
Substitut=".0000":""
[MeasureYear3Num]
Measure=Calc
Formula=MeasureYear3
Substitut=".0000":""
[MeasureMonth3Num]
Measure=Calc
Formula=MeasureMonth3
Substitut=".0000":""
[MeasureDay3Num]
Measure=Calc
Formula=MeasureDay3
Substitut=".0000":""
[MeterDate1]
Meter=String
MeasureName=MeasureMonth1Num
MeasureName2=MeasureDay1Num
MeasureName3=MeasureYear1Num
MeterStyle=FontStyle
X=0
Y=0
Text=Date: %1 %2 %3
[MeterTitle1]
Meter=String
MeasureName=MeasureTitle1
MeterStyle=FontStyle
X=r
Y=R
Text=Title: %1
[MeterDuration1]
Meter=String
MeasureName=MeasureDuration1
MeterStyle=FontStyle
X=r
Y=R
Text=Duration: %1"
[MeterText1]
Meter=String
MeasureName=MeasureText1
MeterStyle=FontStyle
SolidColor=0,0,0,100
X=r
Y=R
W=300
H=95
ClipString=1
Text=Text %1
[MeterDate2]
Meter=String
MeasureName=MeasureMonth2Num
MeasureName2=MeasureDay2Num
MeasureName3=MeasureYear2Num
MeterStyle=FontStyle
X=r
Y=R
Text=Date: %1 %2 %3
[MeterTitle2]
Meter=String
MeasureName=MeasureTitle2
MeterStyle=FontStyle
X=r
Y=R
Text=Title: %1
[MeterDuration2]
Meter=String
MeasureName=MeasureDuration2
MeterStyle=FontStyle
X=r
Y=R
Text=Duration: %1"
[MeterText2]
Meter=String
MeasureName=MeasureText2
MeterStyle=FontStyle
SolidColor=0,0,0,100
X=r
Y=R
W=300
H=95
ClipString=1
Text=Text %1
5-13-2011 2-26-16 PM.jpg
Hope this helps get you off and running...
You do not have the required permissions to view the files attached to this post.