Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 2/21/2005(UTC) Posts: 44 Location: Genoa (Italy)
Thanks: 2 times Was thanked: 3 time(s) in 3 post(s)
|
Hello. Is there a formula which counts the bars since the beginning of the year?
Not since the beginning of the data on the chart loaded, just of the year! I expect it to go back to 1 on the first trading session of the new year and increase + 1 for every trading session.
Thank you for your help. F.
|
|
|
|
Rank: Advanced Member
Groups: Moderators, Registered, Registered Users, Subscribers Joined: 10/8/2010(UTC) Posts: 1,960
Thanks: 91 times Was thanked: 155 time(s) in 150 post(s)
|
Originally Posted by: fiorenzo Hello. Is there a formula which counts the bars since the beginning of the year?
Not since the beginning of the data on the chart loaded, just of the year! I expect it to go back to 1 on the first trading session of the new year and increase + 1 for every trading session.
Thank you for your help. F.
Hi, You might try the following formula to see if it gets what you are looking for: Code:BarsSince(ROC(Year(),1,$)<>0)
|
1 user thanked MS Support for this useful post.
|
|
|
Rank: Advanced Member
Groups: Registered, Registered Users, Subscribers Joined: 2/21/2005(UTC) Posts: 44 Location: Genoa (Italy)
Thanks: 2 times Was thanked: 3 time(s) in 3 post(s)
|
You got it! :) Perfect. Thanks!
|
|
|
|
Users browsing this topic |
Guest (Hidden)
|
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.