stangstang / Publications
Forum
I can use CiMA in experts but not use it in indicator ,why?
i write such code in experts , it can work ! #include <Indicators\Trend.mqh> CiMA *ma; //+------------------------------------------------------------------+ //| Custom indicator initialization function | //+------------------------------------------------------------------+
how to get data from calling technical indicator class ?
generaly , if you want to get indicator data, you can use the code such as: double macd[]; int macdHandle=iMACD(Symbol(),PERIOD_CURRENT,12,26,9,PRICE_CLOSE); ArraySetAsSeries(macd,true); CopyBuffer(macdHandle,0,0,100,macd); printf("%s %f %f %f",Symbol(),macd[0],macd[1],macd[2]); now
why not has volume in MqlTick data
hi , l have a problem ,l wish get tick volume and lused the code such as : void OnTick () { MqlTick last_tick; //--- if ( SymbolInfoTick ( Symbol (),last_tick)) { Print (last_tick.time, ": Bid = " ,last_tick.bid, " Ask = " ,last_tick.ask, " Volume = "