Market Closed?
Please help, How can I find out wether the marked is closed?
ENUM_SYMBOL_TRADE_MODE SymbolInfoInteger(string name, int prop_id);
ENUM_SYMBOL_TRADE_MODE
Identifier | Description |
SYMBOL_TRADE_MODE_DISABLED | Trade is disabled for the symbol |
SYMBOL_TRADE_MODE_LONGONLY | Allowed only long positions |
SYMBOL_TRADE_MODE_SHORTONLY | Allowed only short positions |
SYMBOL_TRADE_MODE_CLOSEONLY | Allowed only position close operations |
SYMBOL_TRADE_MODE_FULL | No trade restrictions |
Trade is disabled while the market is closed, if I remember.
Another option is using the standard library CSymbolInfo class, which can save you some time writing functions.
There's an article related to verifying and checking limitations of your EA.
Cheers,
Lugs
- www.mql5.com
d'oh
Thanks, that'll help
d'oh
Thanks, that'll help