I'm trying to test my code but I keep getting the below errors/messages which prevents me from buying or selling. Thoughts?
2017.05.08 08:46:29.749 2017.04.02 21:08:59 current account state: Balance: 10000.00, Credit: 0.00, Commission: 0.00, Accumulated: 0.00, Assets: 0.00, Liabilities: 0.00, Equity 10000.00, Margin: 0.00, FreeMargin: 10000.00
2017.05.08 08:46:29.749 2017.04.02 21:08:59 calculated account state: Assets: 0.00, Liabilities: 0.00, Equity 10000.00, Margin: 10662.00, FreeMargin: -662.00
2017.05.08 08:46:29.749 2017.04.02 21:08:59 not enough money [market sell 0.10 EURUSD]
2017.05.08 08:46:29.749 2017.04.02 21:08:59 Order send sell failed with error: 4756
I'm new to this forum but I think it's always useful to include the code of your EA
Your FreeMargin -662.00 is less than your broker allowed.
You have two options : up you equity or your leverage.
Anybody kwows how can I match 'calculated account state : Assets' or my broker requirements with code ?
Your FreeMargin -662.00 is less than your broker allowed.
You have two options : up you equity or your leverage.
Anybody kwows how can I match 'calculated account state : Assets' or my broker requirements with code ?
This is my answer :
https://www.mql5.com/en/articles/22

- www.mql5.com
With 1:1 leverage you need $100'000 to open 1 lot on a forex pairs with USD as base currency.
As already suggest, you need to increase your balance or your leverage.
OP posted in May 2017.
I guess that he might have lost interest by now.

- Free trading apps
- Over 8,000 signals for copying
- Economic news for exploring financial markets
You agree to website policy and terms of use
I'm trying to test my code but I keep getting the below errors/messages which prevents me from buying or selling. Thoughts?
2017.05.08 08:46:29.749 2017.04.02 21:08:59 current account state: Balance: 10000.00, Credit: 0.00, Commission: 0.00, Accumulated: 0.00, Assets: 0.00, Liabilities: 0.00, Equity 10000.00, Margin: 0.00, FreeMargin: 10000.00
2017.05.08 08:46:29.749 2017.04.02 21:08:59 calculated account state: Assets: 0.00, Liabilities: 0.00, Equity 10000.00, Margin: 10662.00, FreeMargin: -662.00
2017.05.08 08:46:29.749 2017.04.02 21:08:59 not enough money [market sell 0.10 EURUSD]
2017.05.08 08:46:29.749 2017.04.02 21:08:59 Order send sell failed with error: 4756