It is currently April 27th, 2024, 12:13 am
ActionTimer can't make repeat work
-
- Developer
- Posts: 22631
- Joined: April 19th, 2009, 11:02 pm
- Location: Fort Hunt, Virginia, USA
Re: ActionTimer can't make repeat work
Glad to help!
-
- Moderator
- Posts: 1255
- Joined: February 16th, 2012, 3:32 am
- Location: Berlin, Germany
Re: ActionTimer can't make repeat work
It was clear but additional explanation does not hurt, especially that everyone is not on the same level. I appreciate your help.jsmorley wrote: ↑April 22nd, 2021, 11:15 am I hope I was clear. With this action:
Set1=[!SetVariable CurN "(#CurN#+1)"][!Update][!Redraw][!SetVariable CurS "(#CurN#)"][!Update][!Redraw]
What happens is that on each update of the measure the action option is read and parsed. Any formulas or #Variables# will be resolved at that time. So what will be passed to Rainmeter on the first execution of this statement is:
[!SetVariable CurN "(0+1)"][!Update][!Redraw][!SetVariable CurS "(0)"][!Update][!Redraw]
Then the bangs will be executed in order, but in a sense all at once. So even though you have that extra (and pointless) !Update in the middle, it doesn't matter. The ActionTimer plugin has control of things until the action statement is completed. It's too late to "update" the value of #CurN# in the middle, it has already been resolved and set to "0" at that point, and in effect isn't a variable anymore.
On the other hand, I want to agree with you about the in-necessity of the middle [!Update] bangs but on the practice I get incorrect result without them.
Code:
You do not have the required permissions to view the files attached to this post.
-
- Moderator
- Posts: 1255
- Joined: February 16th, 2012, 3:32 am
- Location: Berlin, Germany
Re: ActionTimer can't make repeat work
Well, strange thing happens. When you have middle [!Update] bangs but don't have middle [!Redraw] bangs the skin reports different values on every refresh.
Pay attention to 1CurN, 1CurS, 1CurW in the About window:
It is the same skin as above just without the [!Redraw] bangs.
This situation kind of reminds me of this https://forum.rainmeter.net/viewtopic.php?f=14&t=35740&start=10#p180485
except that here you get different result every time.
Pay attention to 1CurN, 1CurS, 1CurW in the About window:
It is the same skin as above just without the [!Redraw] bangs.
This situation kind of reminds me of this https://forum.rainmeter.net/viewtopic.php?f=14&t=35740&start=10#p180485
except that here you get different result every time.
You do not have the required permissions to view the files attached to this post.