Support Board
Date/Time: Sat, 23 Nov 2024 18:19:49 +0000
[Programming Help] ACSIL - Cannot fetch live orders
View Count: 100
[2024-08-13 09:40:01] |
gambcl - Posts: 5 |
I am trying to get the list of open/working orders for all accounts using GetOrderForSymbolAndAccountByIndex(). I am looping over all accounts and passing in the symbol and account, using an index starting at 0 for each account, however I never get any orders returned. I have also tried using an empty string for the symbol which the docs say should return orders for all symbols, and still nothing. I am creating a buy limit order on the chart, I can see the limit order on the chart, I can see the limit order in the Orders window, but GetOrderForSymbolAndAccountByIndex always returns SCTRADING_ORDER_ERROR. Is there another way to fetch all live orders for all accounts? UPDATE: I must be doing something stupid - I tried changing to GetOrderByIndex() just to see if it can fetch orders from the same symbol/account as the chart, and that also just returns SCTRADING_ORDER_ERROR, even when I can see my limit order on the same chart as the study. Date Time Of Last Edit: 2024-08-13 10:25:32
|
[2024-08-13 10:33:48] |
gambcl - Posts: 5 |
Never mind, it looks like I had to set sc.SendOrdersToTradeService to true (even though I am not sending any orders from ACSIL). Once that is set I can see the orders being returned. |
To post a message in this thread, you need to log in with your Sierra Chart account: