Looks to be a rounding problem. When I pass the exact literal numbers, my trade works. However, if I calculate these numbers, I get a 130 error. The numbers print fine, but I assume that there is enough of a rounding error to cause the problem. Is there a way to round these floating point numbers? Any ideas?
I think I solved the problem with the NormalizeDouble function.
In my opinion You set stops too closely to price. (see MarketInfo(Symbol(),MODE_STOPS);)

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
I still have not figured out a pattern as to when it works and when it does not. But if anyone has seen this problem before can can share some insight, that would be much appreciated.
Thanks.