Announcement

Collapse
No announcement yet.

Need Help to Convert MT4 script to EFS

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Need Help to Convert MT4 script to EFS

    I was wondering if someone could help me out by converting an MT4 indicator script to EFS. I am not at all good with computer and would be very greatful for your help.

    Here is how the MT4 Script look like.

    #property indicator_chart_window
    #property indicator_buffers 4
    #property indicator_color1 Red
    #property indicator_width1 1
    #property indicator_color2 Lime
    #property indicator_width2 1
    #property indicator_color3 Red
    #property indicator_width3 1
    #property indicator_color4 Lime
    #property indicator_width4 1

    extern int SignalGap = 4;
    extern int ShowBars = 500;

    int dist=24;

    double b1[];
    double b2[];
    double b3[];
    double b4[];

    int init() {

    SetIndexStyle(0,DRAW_LINE,STYLE_SOLID,1);
    SetIndexStyle(1,DRAW_LINE,STYLE_SOLID,1);
    SetIndexStyle(2,DRAW_ARROW,STYLE_SOLID,1);
    SetIndexStyle(3,DRAW_ARROW,STYLE_SOLID,1);

    SetIndexBuffer(0,b1);
    SetIndexBuffer(1,b2);
    SetIndexBuffer(2,b3);
    SetIndexBuffer(3,b4);

    SetIndexArrow(2,234);
    SetIndexArrow(3,233);

    return(0);
    }

    int start() {

    int k,i,j,limit,hhb,llb;

    if (ShowBars >= Bars) ShowBars = Bars;

    for (i=0;i<ShowBars;i++) {

    b1[i]=0;
    b2[i]=0;
    b3[i]=0;
    b4[i]=0;

    hhb = iHighest(Symbol(),0,MODE_HIGH,dist,i-dist/2);
    llb = iLowest(Symbol(),0,MODE_LOW,dist,i-dist/2);


    if (i==hhb)
    b3[i]=High[hhb]+SignalGap*Point;

    if (i==llb)
    b4[i]=Low[llb]-SignalGap*Point;

    b1[i]=High[hhb];//+SignalGap*Point;
    b2[i]=Low[llb];//-SignalGap*Point;

    }
    return(0);
    }

  • #2
    sopheapsam
    I am not familiar with Metatrader's language so I can't offer any guidance on converting your script to efs. Perhaps some other user who is familiar with the language may be able to assist you with this.
    In the mean time if you are interested in learning how to program in EFS then I would suggest that you begin by reviewing the JavaScript for EFS video series and the Core JavaScript Reference Guide. Those will provide you with a thorough introduction to programming in JavaScript which is at the foundation of EFS. Then go through the EFS KnowledgeBase and study the Help Guides and Tutorials which will provide you with the specifics of EFS.
    If at any time you have a question on a specific programming issue post it here and someone will try to assist or guide you in resolving it.
    If instead you are just looking for someone to write the script for you then you may want to review the FAQ: How can I get my custom study built?
    Alex


    Originally posted by sopheapsam
    I was wondering if someone could help me out by converting an MT4 indicator script to EFS. I am not at all good with computer and would be very greatful for your help.

    Here is how the MT4 Script look like. <SNIP>

    Comment

    Working...
    X