Support Board
Date/Time: Tue, 15 Apr 2025 14:29:11 +0000
Resetting Internal Order ID's
View Count: 130
[2025-03-21 14:51:26] |
kam2001 - Posts: 86 |
Hi, Everytime I place an order the internal order ID is incremented and to find an existing order i am doing a for loop in my code. Is it possible to reset the internal order ID at start of each day or once it reached to certain number so that it starts again from number 1, which will help me to avoid keep changing max value (2000)in for loop. Thanks for(int i = 0; i < 2000; i++) {
sc.GetOrderByOrderID(i, ExistingOrder) } |
[2025-03-21 21:55:21] |
Sierra_Chart Engineering - Posts: 19226 |
No there is no possibility of 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-04-05 08:11:03] |
kam2001 - Posts: 86 |
Thanks for the response, so if it is not possible than in that case, Is there a function that could get me the Internal ID of the very recent order, may it be a working, opened, filled or even cancelled order without looping(iterating) ?
Date Time Of Last Edit: 2025-04-05 08:12:33
|
[2025-04-08 01:28:25] |
ForgivingComputers.com - Posts: 1040 |
Is there a function that could get me the Internal ID of the very recent order, may it be a working, opened, filled or even cancelled order without looping(iterating)]?
Each chart has a list of trades. Use sc.GetTradeListSize to get the size of the list, then loop through the list using sc.GetTradeListEntry
Automated Trading From an Advanced Custom Study: sc.GetTradeListEntry() |
To post a message in this thread, you need to log in with your Sierra Chart account: