https://docs.rainmeter.net/manual/plugins/fileview/#Path
This can be resolved like this:Note: While #Variables# can be used in the parent Path option, [SectionVariables] cannot, as this is ambiguous with the parent definition in a child measure.
Code: Select all
[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1
[Variables]
Name1=Rainmeter
Link1="C:\Program Files\Rainmeter\Rainmeter.exe"
[MeasurePath1]
Measure=String
String=#Link1#
[MeasureFolder1]
Measure=String
String=#Link1#
RegExpSubstitute=1
Substitute="^(.*)\\(.*)$":"\1"
OnUpdateAction=[!SetOption MeasureExeIcon1 Path "[MeasureFolder1]"]
UpdateDivider=-1
DynamicVariables=1
[MeasureFileName1]
Measure=String
String=#Link1#
RegExpSubstitute=1
Substitute="^(.*)\\(.*)$":"\2"
[MeasureExeIcon1]
Measure=Plugin
Plugin=FileView
;Path=WaitForIt
DynamicVariables=1
ShowDotDot=0
ShowFolder=0
WildcardSearch=[MeasureFileName1]
Index=1
Type=Icon
[MeterImage1]
Meter=Image
MeasureName=MeasureExeIcon1
LeftMouseUpAction=["[MeasurePath1]"]
Aside...
I'm not crazy about this limitation, as I'm not a fan of "this always works this way unless it doesn't" stuff. Having said that, the problem is that with parent / child functionality like WebParser and FileView, there is great advantage to the fact that a parent can also be a child (as [MeasureExeIcon1] is in this case) and a child can also be a parent (which can be used to good effect in WebParser). That raises this issue, where Path=[SomeMeasure] risks being ambiguous. If you think about it, Path=[SomeMeasure] could clearly be a reference to a parent in a child, and could clearly be a [SectionVariable] in a parent, but those roles are not, and should not be, that clearly defined.
We probably should never have used [MeasureName] as the format defining a relationship between a child and and parent in these types of measures, but should have used something unique like URL={SomeMeasure} or whatever, but in fairness, the current approach was created long, long before the idea of [SectionVariables] was even a twinkle in our eyes. Sometimes we have to sleep in the bed we have made, that is the cost of backwards compatibility.
For the sake of consistency, I think we will need to look at the approach we used with WebParser, where you use URL=[SomeMeasure] to define a child relationship to a parent, and URL=[&SomeMeasure] to alert Rainmeter that this is a reference to the value of another measure, that it should be treated as a [SectionVariable].