Waldor Bray Silva Cubas:
Hello everyone,
I need the mql5 code to get the selected symbols of MetaTrader 5 into a string Array.
The result Array will be similar to:
string Symbols[]={"USDJPY","XAUUSD","EURGBP",......................................................}
Can you help me with the code.
Thanks
What does "selected symbols" mean? Do you mean the current chart?
You need to use:
SymbolsTotal
SymbolName
and SymbolInfoInteger with SYMBOL_SELECT
Taras Slobodyanik:
You need to use:
Ok Thanks,
I have the code:
string Symbols[];
for(int i=0;i<SymbolsTotal(true);i++){
ArrayResize(Symbols,ArraySize(Symbols)+1);
Symbols[i]=SymbolName(i,true);
}

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
Hello everyone,
I need the mql5 code to get the selected symbols of MetaTrader 5 into a string Array.
The result Array will be similar to:
string Symbols[]={"USDJPY","XAUUSD","EURGBP",......................................................}
Can you help me with the code.
Thanks