Gap between Bid prices

To add comments, please log in or register
Ali D32
28
Ali D32  

Hi

It's part of my code:

Print(" Open:", OrderOpenPrice(), " Bid:",Bid);
if(Bid-OrderOpenPrice()>=(30*Point))
{
        // Send Order
}

Output in journal of strategy tester:


Why Bid price jump from 0.87801 to 0.87822? 

In this situation my expert goes wrong(30Pip distance in condition). because condition should be true in 0.87812 instead of 0.87822

This gap is normal or not? if yes how can i control my orders send exactly in 30pip distance?

rod178
276
rod178  
Ali D32:

Hi

It's part of my code:

Output in journal of strategy tester:


Why Bid price jump from 0.87801 to 0.87822? 

In this situation my expert goes wrong(30Pip distance in condition). because condition should be true in 0.87812 instead of 0.87822

This gap is normal or not? if yes how can i control my orders send exactly in 30pip distance?

yes, normal

john.brave
18
john.brave  
Hi Ali, i don't know about mt4 programming but i think your EA will make a pending order.
William Roeder
20228
William Roeder  
Ali D32: Why Bid price jump from 0.87801 to 0.87822? 

In this situation my expert goes wrong(30Pip distance in condition).

That is a 2.1 PIP distance. A PIP is not a point.
           What is a TICK? - MQL4 and MetaTrader 4 - MQL4 programming forum
To add comments, please log in or register