Support Board
Date/Time: Tue, 25 Feb 2025 22:56:28 +0000
determine the session end date time in ACSIL
View Count: 1955
[2018-01-20 10:50:08] |
Cavalry3162 - Posts: 523 |
Hello SC, i've found this snippet in your ACSIL documentation: SCDateTime StartDateTime = sc.GetTradingDayStartDateTimeOfBar(sc.BaseDateTimeIn[sc.Index]);
int StartBarIndex = sc.GetContainingIndexForSCDateTime(sc.ChartNumber, StartDateTime); to determine the bar index for the beginning of the "current" session... however, i would need to determine the End of the current session (even if its in the future) too so i searched for a sc.GetTradingDayEndDateTimeOfBar method but it wasnt there... Is there a way to get that session end info? thank you, Andreas |
[2018-01-22 21:29:50] |
|
Just simply add 24 hours - 1 second to StartDateTime. Refer to: Working with the SCDateTime Variables and Values: Date and Time Math 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, *change* to the Teton service: Sierra Chart Teton Futures Order Routing |
[2021-05-05 15:20:44] |
User30743 - Posts: 365 |
ha. are you serious? this obviously does not work. sessions are not 24 hours long. US futures start at 8:30 and ends at 15:15. EU futures start and end at different times. ... etc.. and what about the sessions that are shortened due to holidays? no clue how to get the last index of a trading session, which is extremely important for backtesting intraday strategies to prevent holding overnight. i am really wondering that ACSIL API does not provide such an important thing as the last index of a trading session. there are tons of fairly useless functions but the most important ones are not there. quite sad (: Date Time Of Last Edit: 2021-05-05 15:26:26
|
To post a message in this thread, you need to log in with your Sierra Chart account: