Support Board
Date/Time: Mon, 25 Nov 2024 04:24:06 +0000
Post From: ACSIL: Flatten Orders & Stop Trading Before Market Close
[2024-04-08 17:30:32] |
User582682 - Posts: 3 |
Thank you both for your replies. For now, what I'm doing is taking market segments within certain exchanges and creating a general script for those segments. For example, I'll close agricultural trades and cease trading at 2 pm ET and then reopen again at 6 pm ET. This way, I don't have to write the same script in a ton of different ways. For holidays, I'm simply stopping all trading during these periods. I will flip the trading state during these times to ensure no orders go through and all are flattened. Maybe down the road, I will create scripts that auto-update themselves later in case of any time or holiday changes, but for now, this will do. I just find it shocking that after all these years there still isn't a function to simply pull the market close time. It would certainly cut down on the lines of code I need to write. |