insert colour

 
i draw two moving averages in the chart, say 100 and 200 for example, can i insert/put a colour between them, to look just like an ichimokou cloud? many tks in advance your prompt reply.
 
try use custom indicator with histogram drawing type. You fill two lines with Your MA values and histogram will be drawn between these lines
 
tks vm Slawa but if yu dont mind need some more detailed info on that how i can do. tks again your prompt reply.
 
//+------------------------------------------------------------------+
//|                                                     ma-cloud.mq4 |
//|                      Copyright © 2004, MetaQuotes Software Corp. |
//|                                       https://www.metaquotes.net/ |
//+------------------------------------------------------------------+
#property copyright "Copyright © 2004, MetaQuotes Software Corp."
#property link      "https://www.metaquotes.net/

#property indicator_chart_window
#property indicator_buffers 2
#property indicator_color1 Blue
#property indicator_color2 Red
//---- input parameters
extern int       MA_Period1=200;
extern int       MA_Period2=100;
//---- indicator buffers
double ExtBlueBuffer[];
double ExtRedBuffer[];

//+------------------------------------------------------------------+
//| Custom indicator initialization function                         |
//+------------------------------------------------------------------+
int init()
  {
   int max=MathMax(MA_Period1,MA_Period2);
//---- first positions skipped when drawing
   SetIndexDrawBegin(0,max);
   SetIndexDrawBegin(1,max);
//---- 2 indicator buffers mapping
   SetIndexBuffer(0,ExtBlueBuffer);
   SetIndexBuffer(1,ExtRedBuffer);
//---- drawing settings
   SetIndexStyle(0,DRAW_HISTOGRAM);
   SetIndexStyle(1,DRAW_HISTOGRAM);
//---- initialization done
   return(0);
  }
//+------------------------------------------------------------------+
//|                                                                  |
//+------------------------------------------------------------------+
int start()
  {
   int limit;
   int counted_bars=IndicatorCounted();
//---- check for possible errors
   if(counted_bars<0) return(-1);
//---- last counted bar will be recounted
   if(counted_bars>0) counted_bars--;
   limit=Bars-counted_bars;
//---- main loop
   for(int i=0; i<limit; i++)
     {
      ExtBlueBuffer[i]=iMA(NULL,0,MA_Period1,0,MODE_SMA,PRICE_CLOSE,i);
      ExtRedBuffer[i]=iMA(NULL,0,MA_Period2,0,MODE_SMA,PRICE_CLOSE,i);
     }
//---- done
   return(0);
  }
//+------------------------------------------------------------------+


result is
for this result set chart as foreground (F8 - Chart Properties - Common tab) and set thick line in the indicator properties.

 
Slawa - i cant find words to say thank you but its still dificult for me and other many traders i hv talked. well, lets put in this way. i am interesting 21 and 55 exponential moving averages. most of participants interested about that. So last but not least wuld be very much obliged if yu can make a custom indicator about that and put it in your site so all of us can download. repeat 21 and 55 exponential moving averages. thanks again your nice support
 
create new custom indicator, pass over all wizard, delete all the generated text, copy source text from this page and paste this one instead of deleted text.
MA_Period1 set to 21
MA_Period2 set to 55
MODE_SMA parameters in the iMA calls replace to MODE_EMA
press compile button
and use your own custom indicator
 
Slawa tks vm indeed
Reason: