Login Page - Create Account

Support Board


Date/Time: Fri, 07 Nov 2025 19:31:39 +0000



[Programming Help] - sc.IsLastBarClosedBasedOnElapsedTime does not work for daily, weekly bars

View Count: 195

[2025-10-19 21:30:59]
rajeshh - Posts: 50
Hello - I have the same custom study for intra-day that I would like to apply for higher timeframe historical charts - daily, weekly. Most of the rules of the study are determined at the close of the current/last bar. On a higher timeframe chart, the check to see if bar has closed does not work because the next bar is not created yet. For e.g, I want to place orders at the end of the day for a daily chart, or the weekend for a weekly chart.

As it stands, sc.IsLastBarClosedBasedOnElapsedTime, seems like the only function that could be used for this scenario, but it does not return true when run after the end of the day for a daily chart, or on the weekend for a weekly chart. Is it possible to make this work for higher timeframe charts?
[2025-10-22 14:38:45]
Sierra_Chart Engineering - Posts: 21330
We will check on this.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
[2025-10-30 19:24:45]
Sierra_Chart Engineering - Posts: 21330
We have looked into this. In the case of a Daily chart bar, it would not be considered closed until the beginning of the next day which would be exactly at midnight (00:00:00) in the next day.
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2025-10-30 19:25:33
[2025-10-30 21:53:09]
rajeshh - Posts: 50
Ok. For a weekly chart, would it then be Monday morning 00:00:00?
[2025-11-04 20:09:44]
Sierra_Chart Engineering - Posts: 21330
It would either be Sunday or Monday morning at 00:00:00 but it is based upon this setting:
General Settings Window: Use Monday as Start of Week Instead of Sunday (Global Settings >> General Settings >> General >> Data)
Sierra Chart Support - Engineering Level

Your definitive source for support. Other responses are from users. Try to keep your questions brief and to the point. Be aware of support policy:
https://www.sierrachart.com/index.php?l=PostingInformation.php#GeneralInformation

For the most reliable, advanced, and zero cost futures order routing, use the Teton service:
Sierra Chart Teton Futures Order Routing
Date Time Of Last Edit: 2025-11-04 20:10:09

To post a message in this thread, you need to log in with your Sierra Chart account:

Login

Login Page - Create Account