FXCM Forex Trading

Request Indicator MA as Lines

If you need an Indicator or Signal developed or translated from other language, please post all Indicator development REQUESTS to this section here.

Moderator: admin

Request Indicator MA as Lines

Postby Ehab.Ali » Wed Sep 27, 2017 9:46 am

can you please help with that i found an indicator but closed source and not working
i need the same idea and settings in a working indicator for mt4 plus alert when price touch any line
Lines auto change it self with moving price
and thank you a lot

MA-Horizontal-Lines-Indicator.ex4
(69.48 KiB) Downloaded 10 times
Ehab.Ali
 
Posts: 36
Joined: Tue May 31, 2016 2:10 pm

Re: Request Indicator MA as Lines

Postby Apprentice » Mon Oct 02, 2017 5:01 am

Unfortunately I can not help you.
The indicator is encoded in EX4 format.
Can you provide MQ4 version, a description, a screenshot?
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 17153
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Request Indicator MA as Lines

Postby Ehab.Ali » Mon Oct 02, 2017 6:38 am

yes i can provide screenshots sir
first thanks for answer

idea is making an indicator for mt4 create 4 dynamic lines for 4 moving averages (ema,sma, etc) current price
with alert if price touch any of this lines

example
ma 1 - 4h price = 151.30
then create Horizontal line with lable (sma 1 frame 4h) on price 151.30
if moving price changes line auto movr to the new price

same option for the other ma2 / ma3 / ma4
attached screen shots for indicator setting

thank you a lot sir
Attachments
1.png
2.png
3.png
4.png
5.png
Ehab.Ali
 
Posts: 36
Joined: Tue May 31, 2016 2:10 pm

Re: Request Indicator MA as Lines

Postby Apprentice » Tue Oct 03, 2017 4:02 am

Your request is added to the development list under Id Number 3915
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 17153
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Request Indicator MA as Lines

Postby Apprentice » Tue Oct 03, 2017 5:07 am

If you decide to TS2 platform.
Try this TS2 / Marketscope version
viewtopic.php?f=17&t=65142&p=115232#p115232
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 17153
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Request Indicator MA as Lines

Postby Ehab.Ali » Tue Oct 03, 2017 8:46 am

Apprentice wrote:If you decide to TS2 platform.
Try this TS2 / Marketscope version
viewtopic.php?f=17&t=65142&p=115232#p115232



THANK YOU SIR BUT I'M WORK ON MT4
Ehab.Ali
 
Posts: 36
Joined: Tue May 31, 2016 2:10 pm

Re: Request Indicator MA as Lines

Postby Apprentice » Tue Oct 03, 2017 12:36 pm

I'm aware of that.
The Mq4 version is in the pipeline.
This was for the TS2 community.
User avatar
Apprentice
FXCodeBase: Confirmed User
 
Posts: 17153
Joined: Thu Dec 31, 2009 11:59 am
Location: Zagreb, Croatia

Re: Request Indicator MA as Lines

Postby Alexander.Gettinger » Thu Oct 05, 2017 11:19 am

Unfortunately, I can not start the indicator.
It writes a message "The name of this software cannot be changed".

Can you provide screenshots and description?
Alexander.Gettinger
FXCodeBase: Confirmed User
 
Posts: 2770
Joined: Wed Mar 31, 2010 9:40 pm
Location: Russia, Omsk

Re: Request Indicator MA as Lines

Postby Ehab.Ali » Fri Oct 06, 2017 6:59 am

Alexander.Gettinger wrote:Unfortunately, I can not start the indicator.
It writes a message "The name of this software cannot be changed".

Can you provide screenshots and description?



Sir thanks in advance
Can you forget the attached indicator and help me with the idea to create this indicator

idea is making an indicator for mt4 create 4 dynamic lines for 4 moving averages (ema,sma, etc) current price
with alert if price touch any of this lines

example
ma 1 - 4h price = 151.30
then create Horizontal line with lable (sma 1 frame 4h) on price 151.30
if moving price changes line auto movr to the new price

same option for the other ma2 / ma3 / ma4
attached screen shots for indicator setting

thank you a lot sir
Ehab.Ali
 
Posts: 36
Joined: Tue May 31, 2016 2:10 pm

Re: Request Indicator MA as Lines

Postby Ehab.Ali » Fri Oct 06, 2017 7:11 am

example create 4 lines same as moving average

Code: Select all
#property indicator_chart_window

int init() {
   return (0);
}

int deinit() {
   return (0);
}

int start() {
   int l_ind_counted_0 = IndicatorCounted();
   ObjectsDeleteAll(0, OBJ_HLINE);
 
   double l_ima_4 = iMA(Symbol(), PERIOD_CURRENT, 5, 0, MODE_EMA, PRICE_CLOSE, 0);
   double l_ima_12 = iMA(Symbol(), PERIOD_CURRENT, 20, 0, MODE_SMA, PRICE_CLOSE, 0);
   double l_ima_20 = iMA(Symbol(), PERIOD_CURRENT, 30, 0, MODE_EMA, PRICE_CLOSE, 0);
   double l_ima_28 = iMA(Symbol(), PERIOD_CURRENT, 60, 0, MODE_SMA, PRICE_CLOSE, 0);



   
   drawLine(l_ima_4, DoubleToStr(l_ima_4, Digits),DarkGray , 1);
   drawLabel("5", l_ima_4, DarkGray);
   drawLine(l_ima_12, DoubleToStr(l_ima_12, Digits), DarkGray, 1);
   drawLabel("20", l_ima_12, DarkGray);
   drawLine(l_ima_20, DoubleToStr(l_ima_20, Digits), DarkGray, 1);
   drawLabel("30", l_ima_20, DarkGray);
   drawLine(l_ima_28, DoubleToStr(l_ima_28, Digits), DarkGray, 1);
   drawLabel("60", l_ima_28, DarkGray);

   
   return (0);
}

void drawLabel(string a_name_0, double a_price_8, color a_color_16) {
   if (ObjectFind(a_name_0) != 0) {
      ObjectCreate(a_name_0, OBJ_TEXT, 0, Time[10], a_price_8);
      ObjectSetText(a_name_0, a_name_0, 10, "Arial", CLR_NONE);
      ObjectSet(a_name_0, OBJPROP_COLOR, a_color_16);
      return;
   }
   ObjectMove(a_name_0, 0, Time[10], a_price_8);
}

void drawLine(double a_price_0, string a_name_8, color a_color_16, int ai_20) {
   if (ObjectFind(a_name_8) != 0) {
      ObjectCreate(a_name_8, OBJ_HLINE, 0, Time[0], a_price_0, Time[0], a_price_0);
      if (ai_20 == 1) ObjectSet(a_name_8, OBJPROP_STYLE, STYLE_SOLID);
      else ObjectSet(a_name_8, OBJPROP_STYLE, STYLE_DOT);
      ObjectSet(a_name_8, OBJPROP_COLOR, a_color_16);
      ObjectSet(a_name_8, OBJPROP_WIDTH, 1);
      return;
   }
   ObjectDelete(a_name_8);
   ObjectCreate(a_name_8, OBJ_HLINE, 0, Time[0], a_price_0, Time[0], a_price_0);
   if (ai_20 == 1) ObjectSet(a_name_8, OBJPROP_STYLE, STYLE_SOLID);
   else ObjectSet(a_name_8, OBJPROP_STYLE, STYLE_DOT);
   ObjectSet(a_name_8, OBJPROP_COLOR, a_color_16);
   ObjectSet(a_name_8, OBJPROP_WIDTH, 1);
}


but need to add options to the settings like
choose m1 / color /PERIOD / method / timeframe
choose m2 / color /PERIOD/ method / timeframe
choose m3 / color /PERIOD/ method / timeframe
choose m4 / color /PERIOD/ method / timeframe
alert when price touch the line
Ehab.Ali
 
Posts: 36
Joined: Tue May 31, 2016 2:10 pm

Next

Return to Indicator and Signal Requests

Who is online

Users browsing this forum: No registered users and 8 guests