×

Sign up and get MultiCharts free

Use its powerful simulation mode with data included out of the box. Just fill out the form and start honing your trading skills with a few clicks.

Changes - MultiCharts

Changes

Jump to navigation Jump to search

Why an Order Was or Was Not Executed

30 bytes added, 16:32, 12 September 2022
==Order and Position Tracker==
If an order was generated and sent from the script to a broker plugin, it is displayed in the [[Order_and_Position_Tracker|Order and Position Tracker]] on the Orders tab. If an order is filled, you can see it's its execution price and details (see [[Order_and_Position_Tracker#Orders_Tab|Orders Tab]]).
<br>
There are 2 possible reasons why an order is not placed at the broker:
==Monitoring from Script==
This method is extremely useful not only for backtesting, since the [[Order_and_Position_Tracker|Order and Position Tracker ]] has nothing in common with the historical calculation process, but also for live auto trading because you can see the strategy logic printed out in real-time.
Adding the following line under the same conditions right before the line, when generating your buy/sell orders, will help you to understand at what particular bar, when, and at what price your order is triggered in the code:
<br>

Navigation menu