Selecting symbols on History function that contains specific letters.
Hi folks,
I would like to select in Deals or Orders History any symbol that begins with "EUR" letters.
Even if my EA is on "EURUSD" chart, I would like to get "history deals" from "EURCAD" for example, or any symbol that begins with "EUR..."
The following is my code to select only the Symbol on chart. How can I do this?
With SymbolInfoString(), you can access BASE_CURRENCY, PROFIT_CURRENCY and MARGIN_CURRENCY. Read on the documentation and you'll find your answer!
instead of if(HistoryDealGetString(deal_ticket,DEAL_SYMBOL)==DXY***)
try
string abc = HistoryDealGetString(deal_ticket,DEAL_SYMBOL) ;
if(StringFind(abc,"DXY"){
//whatever you want to do
}
- www.mql5.com
instead of if(HistoryDealGetString(deal_ticket,DEAL_SYMBOL)==DXY***)
try
string abc = HistoryDealGetString(deal_ticket,DEAL_SYMBOL) ;
if(StringFind(abc,"DXY"){
//whatever you want to do on
}
Hi folks,
I would like to select in Deals or Orders History any symbol that begins with "EUR" letters.
Even if my EA is on "EURUSD" chart, I would like to get "history deals" from "EURCAD" for example, or any symbol that begins with "EUR..."
The following is my code to select only the Symbol on chart. How can I do this?