How can I store the entry price for my OrderSend functions up until the bias changes?
Entry for long: H1_Buy_Touch = "H1 Buy Touch"; (global variable)
Entry for short: H1_Sell_Touch = "H1 Sell Touch"; (global variable)
These biases can change on every hour as it is checked on ever new bar. Thing is, when the OrderEntry(1) is called, the entry price will be near enough different every time as the calulcations are done in that void straight away.
I want to remember the FIRST time it's called and the corresponding price. OrderEntry pushes out Pending buy and sell stops. They can be cancelled every hour if the stops, targets and lots require adjusting. If thats the case, on every tick it then start here again (below) and if the bias is applicable, it'll push out 4 sets of new pending orders with everything new INCLUDING a new entry price. I don't want the entry price to change though... I want to use the same entry price up until either the orders are entered into the market, or the bias changes to "None"
Allow the use of cookies to log in to the MQL5.com website.
Please enable the necessary setting in your browser, otherwise you will not be able to log in.
You are signed in. Two-factor authentication has been disabled. Set it up again and scan a new QR code, or continue with two-factor authentication disabled.
How can I store the entry price for my OrderSend functions up until the bias changes?
Entry for long: H1_Buy_Touch = "H1 Buy Touch"; (global variable)
Entry for short: H1_Sell_Touch = "H1 Sell Touch"; (global variable)
These biases can change on every hour as it is checked on ever new bar. Thing is, when the OrderEntry(1) is called, the entry price will be near enough different every time as the calulcations are done in that void straight away.
I want to remember the FIRST time it's called and the corresponding price. OrderEntry pushes out Pending buy and sell stops. They can be cancelled every hour if the stops, targets and lots require adjusting. If thats the case, on every tick it then start here again (below) and if the bias is applicable, it'll push out 4 sets of new pending orders with everything new INCLUDING a new entry price. I don't want the entry price to change though... I want to use the same entry price up until either the orders are entered into the market, or the bias changes to "None"