Stop loss = 1? huh?
Results 1 to 5 of 5

Thread: Stop loss = 1? huh?

  1. #1
    Hi Guys,

    You have been very useful but wondering if you could help explain this...

    When I conduct my EA, the print command shows me the value for var3 (my stop) is 1. How does this develop this amount?


    Here is the output:
    Recmax: 1.9859 Recmin: 1.9782 Stop: 1

    Im hoping the value to be 50 points then Recmax which would be like 1.9359



    ==========
    Code
    ==========



    int var3 = NormalizeDouble(RectanglePriceMax,Digits)-500*Stage;

    OrderSend(Symbol(),OP_BUYLIMIT,1,NormalizeDouble(R ectanglePriceMin,Digits),3,var3,NormalizeDouble(Re ctanglePriceMin,Digits) 500*Stage,Order Sent, 16384,0,Green);


    Printing(Recmax:, RectanglePriceMax, Recmin:, RectanglePriceMin, Stop: , var3, This is really for its bullish pattern);

  2. #2
    Is that a mistake you made posting here or is there really a gap in your code
    here : int var3 = NormalizeDouble(RectanglePriceMax,D igits)-500DecisionStage;

    its supposed to be Digits...

  3. #3
    Hmm I donno why when I copied it Occurred, but I took out There and put it into notepad and there was N't Any Distances, so retyped it in ... but ran it and got the Exact Same value of 1 ... hmmmm

  4. #4
    Quote Originally Posted by ;
    Recmax: 1.9859 Recmin: 1.9782 Stop: 1

    Im hoping the value to be 50 points less then Recmax which would be like 1.9359

    ...

    int var3 = NormalizeDouble(RectanglePriceMax,Digits)-500*Stage;
    Hello, trader346, the error is that you announce var3 as an 'int' but assign a double value to it, so it gets truned to an integer (in this case to '1').

    Try this:

    dual var3 = NormalizeDouble(RectanglePriceMax,Digits)-500*Point;

  5. #5

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
This website uses cookies
We use cookies to store session information to facilitate remembering your login information, to allow you to save website preferences, to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners.