I'm exploring advanced order handling capabilities. Specifically, I am interested in adding a feature to my addon tool that programmatically rejects orders based on certain criteria.
The scenario I want to address is the following: If an order is submitted with a contract volume that exceeds a predefined threshold, the order should be automatically rejected before execution. For example, if the threshold is set to 100 contracts, any order request to buy or sell more than 100 contracts should be rejected by the code when its in the Submitted state.
Could you please guide me on whether this functionality can be implemented in NinjaTrader? If yes, I would appreciate any pointers on which classes or methods I should use to customize this order rejection criteria. Also, is there any sample code available that demonstrates similar custom order rules?
Thank you in advance for your assistance!
Best regards,
Aviram Y

Comment