SymbolSelect()

 
How do i exactly use symbolselect function?
I used it this way it doesn't work

String pair="EURUSD";
SymbolSelect(Pair,true);
Alert (symbol());

 i use alert to see if the symbol is selected but i see it always alerts usdchf by default,
Please me with,  write the exactly code which select EURUSD symbol
 
Please don't double or triple post.
 
mahmood0:
How do i exactly use symbolselect function?
I used it this way it doesn't work

String pair="EURUSD";
SymbolSelect(Pair,true);
Alert (symbol());

 i use alert to see if the symbol is selected but i see it always alerts usdchf by default,
Please me with,  write the exactly code which select EURUSD symbol
string pair = "EURUSD";

if(SymbolSelect(pair, true) == true)
   Alert ("EURUSD is selected successfully");
else
   Alert("EURUSD is not selected");
 
Sergei Vladimirov:
The code you wrote returns true(either mine),
But if really eurusd is selected why does alert() still show eurusd?
I mean if you use Alert (Symbol());  instead of what you wrote, ot shows USDCHF
 
Alain Verleyen:
Please don't double or triple post.
Ok sorry
 
mahmood0:
The code you wrote returns true(either mine),
But if really eurusd is selected why does alert() still show eurusd?
I mean if you use Alert (Symbol());  instead of what you wrote, ot shows USDCHF

that is impossible.

there is no USDCHF to be found in the print commands.

   Alert ("EURUSD is selected successfully");
else
   Alert("EURUSD is not selected");


however if you mean

Alert(Symbol());

it will simply only alert the chart symbol.

so you use,

if(OrderSymbol()=="EURUSD")
 {
  Alert("EURUSD Selected");
 }


With OrderSelect() so not with SymbolSelect() it depends on what you are trying to do which is a mystery to me as of yet but it seems you are trying to select an order.

 
mahmood0:
How do i exactly use symbolselect function?
I used it this way it doesn't work

String pair="EURUSD";
SymbolSelect(Pair,true);
Alert (symbol());

 i use alert to see if the symbol is selected but i see it always alerts usdchf by default,
Please me with,  write the exactly code which select EURUSD symbol
SymbolSelect () selects a symbol in Market Watch, but Symbol() and other generic functions always are refers to the graphic symbol.
If symbolselect ("symbNom") == false you can not get price information of "symbNom"
Reason: