You are missing trading opportunities:
- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
Registration
Log in
You agree to website policy and terms of use
If you do not have an account, please register
You have an error in OnInit:
if(haHandle=iCustom(_Symbol, _Period, "::Indicators\\heiken_ashi.ex5") == INVALID_HANDLE) return(INIT_FAILED); if(SMA10Handle=iCustom(_Symbol, _Period, "::Indicators\\Examples\\Custom Moving Average.ex5", 10, 0, MODE_SMA) == INVALID_HANDLE) return(INIT_FAILED); if(SMA30Handle=iCustom(_Symbol, _Period, "::Indicators\\Examples\\Custom Moving Average.ex5", 30, 0, MODE_SMA) == INVALID_HANDLE) return(INIT_FAILED);
I still need your help.
I would like to write a report on how many potential pips I could earn and how many pips I actually make or lose.
This piece of code should calculate me how many pips I have in profit or loss:
even if the trade entry price (orderPriceOpen) and the current market price (actualPrice) are correct, the difference between them sometimes returns me 5.9, 2.0, 9.9 and sometimes 0.005900000-05, 0.002000000-05, 0.009900000-05.(sometimes i get a double and sometimes i get a scientific notation).
I don't understand why this happens, and it happens randomly without changing the code.
Furthermore the operation
double actualPips = (actualPrice - orderPriceOpen);
always return 0.0
if you wish, I add all the files of the project as attachments
thanks for your interest and for your help.
What do you think that line does?
It not seems correct, actualPrice should be double
the documentation says that NormalizeDouble () converts a float number to a double with decimals as for the second parameter
ok i solved the problem of message #16, a stupid problem, i solved it by multiplying it
https://charts.mql5.com/31/88/eurusd-m1-metaquotes-software-corp.png
there were 2 weird operations tonight.
as you can see from the chart the ea opened 2 positions at prices that weren't even from the candle spikes.
i am testing the ea in real time and they are the only cases.
yesterday afternoon I downloaded the historical data, does it have something to do with it?
How could that happen?