previous bar OHLC -
1 2 3

thread: previous bar OHLC

  1. #11
    not Functioning:[
    THAT'S A Indiion OF Terrible PROGRAMMING!

  2. #12
    that's your whole article?

    At least put up an error message or something
    Hi LongToBeFree,
    You are supposed to check what You programmed prior to You send out this appliion.
    Just my two pennies

  3. #13
    Hello,
    You are supposed to check what You programmed prior to You send out the program.
    Just my 2 cents
    Did you verify the code ? Until then, I'd make sure that you're careful about libelous statements that you produce.

  4. #14
    Member Nighy's Avatar
    42
    My guess is... you are using it as an indior when LongToBeFree coded it as an EA. The code works fine if you are using it as an EA.

    If its likely to be utilized as an indior, one line has to be added close to the top

    Hope that this helps.

    Regards,
    Zen
    Inserted Code //p ------------------------------------------------------------------ //| GoHan OHLC.mq4 | //| Copyright © 2008, gohanforex.com | //| #91;url#93;http://www.gohanforex.com#91;/url#93; | // ------------------------------------------------------------------ #property copyright Copyright © 2008, gohanforex.com #property link #91;url#93;http://www.gohanforex.com#91;/url#93; #91;b#93;#property indior_chart_window#91;/b#93; //p ------------------------------------------------------------------ //| pro initialization serve | //p ------------------------------------------------------------------ int init() //-- managelowerstatus(#91;url#93;http://www.gohanforex.com#91;/url#93;-RRB-; //-- return(0); //p ------------------------------------------------------------------ //| pro deinitialization function | //p ------------------------------------------------------------------ int deinit() //-- //-- return(0); //p ------------------------------------------------------------------ //| expert start operate | // ------------------------------------------------------------------ int start() //-- Opinion (Open#91;1#93;,High#91;1#93;,Low Cost #91;1#93;,Close#91;1#93;-RRB-; //-- return(0); // ------------------------------------------------------------------ // ------------------------------------------------------------------ //| Manage lower standing | // ------------------------------------------------------------------ void managelowerstatus(series addstatus) ObjectDelete(Lower_Status); should (addstatus! ) =-RRB- ObjectCreate(Lower_Status, OBJ_LABEL, 0, 0, 0);// Establishing obj. ObjectSet(Lower_Status, OBJPROP_CORNER,3); // Reference corner ObjectSet(Lower_Status, OBJPROP_XDISTANCE, 2);// X coordinate ObjectSet(Lower_Status, OBJPROP_YDISTANCE, 1);// Y coordinate ObjectSetText(Lower_Status, addstatus, 9, Verdana, Yellow);

  5. #15
    Junior Member Carroaupk's Avatar
    27
    My guess is... you're using it as an indior when LongToBeFree coded it as an EA. If you're using it as an 12, the code works fine.

    When its likely to be used as an indior, one line needs to be added near the top

    Hope this helps.

    regards,
    Zen
    Works beautifuly.
    Thank you very much

  6. #16
    Member Nighy's Avatar
    42
    Do not thank me, LongToBeFree was the person who wrote the code. I merely pointed out that its EA rather than an indior.

    Next time you get a piece of code, do a Fast test and see if it's something like this

    Inserted Code // ------------------------------------------------------------------ //| expert initialization function | // ------------------------------------------------------------------
    that's tell tale sign the author is currently writing an EA.

    Have fun. =-RRB-

    regards,
    Zen

  7. #17
    My guess is... you are using it as an indior when LongToBeFree coded it as an EA. The code works fine if you are using it as an EA.

    When its likely to be used as an indior, one line needs to be added close to the top

    Hope that this helps.

    Regards,
    Zen
    [code]
    // ------------------------------------------------------------------
    //|...
    Hi Zen,
    You are very smart.
    I appreciate You.

  8. #18
    LongToBeFree,
    Fantastic work!

  9. #19
    Junior Member Carroaupk's Avatar
    27
    don't thank me, LongToBeFree was the person who wrote the code. I just pointed out that its an EA rather than an indior.

    Next time you get a piece of code, then do a Fast check and see if it's something like this

    Inserted Code // ------------------------------------------------------------------ //| expert initialization function | // ------------------------------------------------------------------ that is tell tale sign the writer is writing an EA.

    Have fun. =-RRB-

    regards,
    Zen
    I mean thank you for your effort.
    Saying that it is black magic for me personally I meant exactly that issues.
    You are aware that it must go something like this but there is obviously a detail you are unaware of because of total lack of expertise in programming mql.

  10. #20
    Junior Member sadsuky's Avatar
    26
    It is possible to compare value Open Price for new candle with value Close Price for candle? When possible, the way to code?

    Let say:

    if(Open[1]_New_Candle gt; Close[1]_Previous_Candle)
    print Good

    vice verse

    TQ

  •