[ARCHIVE!] Any rookie question, so as not to clutter up the forum. Professionals, don't pass by. Can't go anywhere without you - 4. - page 393

 
 
rosomah:

Please, help.

I put a modifier of pending orders, in the EA, and it gives me an error - 1 when testing in the Journal.

I.e. - "If I pass unchanged values as function parameters, error 1 (ERR_NO_RSULT) will be generated".

I put a check before modification, but it doesn't help. What is the error? The EA is being tested, but how can I sift out orders with unchanged values?

Print the values pr, stop and take to see what they send to OrderModify
 
Thank you just what we need :)
 

After a long break I decided to write an EA, but here's the problem...

The price in the terminal now looks like this: 1.31126 - 5 decimal places

The variables Bid, Ask, Open[i], High[i], Low[i], Close[i] return the price as 1.3113 - 4 decimal places.

Because of this, the Expert Advisor does not work. How can I fix it?

Please, advise who knows...

 
Acnupuh72:

and variables Bid, Ask, Open[i], High[i], Low[i], Close[i] return the price as follows: 1.3113 - 4 digits.

Because of this, the Expert Advisor does not work. How do I fix it?

Use DoubleToStr(PRICE, 5) when outputting to Print
 
rosomah:

Please help.

I put a modifier of pending orders, in the EA, and it gives me an error - 1 when testing in the Journal.

I.e. - "If I pass unchanged values as function parameters, error 1 (ERR_NO_RSULT) will be generated".

I put a check before modification, but it doesn't help. What is the error? The EA is being tested, but how can I sift out orders with unchanged values?


Fractional numbers must be normalised before they can be compared.
 

Please, advise, is it normal that only 1 order may exist at any given time, but it can close partially (in small lots) and the same graph is shown in the Strategy Tester?

Those equity and balance diverge, although with 1 existing order they should be equal all the time. Is it because of partial closing of lots or is there an error in my code?

 
Please tell me if I can master mql if I (almost) know exel perfectly, because I've seen a program where the codes contain the "moves" of exel but in mql language. Where can I find such an approach to programming?
 
yosuf:
Please tell me if I can master mql if I (almost) know exel perfectly, because I've seen a program where the codes contain the "moves" of exel but in mql language. Where can I find such an approach to programming?
The man can do anything. One can even learn MQL4 in Chinese, Swahili and other equally complex languages.
 
Guys! Somewhere I've seen recommendations for closing a profitable trade in stages. Something like - first close 60% of the initial lot, then 30%. If you've seen it, please send it to the right address.
Reason: