It seems to work ok on my computer. Thank you Sidhartha for your help.
Instead of "break" should it be "close" since I want the candle to
close above or below the trendline depending on the trend? Thank you.

Kindest regards,

Tim




--- In [email protected], "sidhartha70" <[EMAIL PROTECTED]> wrote:
>
> Ummm... strange thing is Tim, that dll is devlishly slow when I look
> at any data sub daily... 1 call to that dll below daily data takes
> 350ms... at daily data it takes 1.5ms... something strange happening
> within that dll. That's for sure.
> 
> As for your alert cross over.... you have these 4 lines at the bottom
> of the AFL code,
> 
> Plot(GP_tlineUp1, "", colorBlue, styleLine|styleThick);
> Plot(GP_tlineUp2, "", colorBlue, styleLine|styleThick);
> Plot(GP_tlineDown1, "", colorRed, styleLine|styleThick);
> Plot(GP_tlineDown2, "", colorRed, styleLine|styleThick);
> 
> what is different between the up & down lines labelled 1 & 2 I'm not
> sure... I haven't studied the code in detail...
> 
> But in principle something like this should work...
> 
> AlertIf(Cross(Close,GP_tlineDown1),"","Break above downward trend
line");
> AlertIf(Cross(GP_tlineUp1,Close),"","Break below upward trend line");
> 
> in theory this line added to the AFL should print the text "Break
> above downward trend line" or "Break below upward trend line" to the
> View>Alert Output window when the close crosses the relevant trend
line...
> 
> 
> 
> 
> --- In [email protected], "Tim" <raven4ns@> wrote:
> >
> > Hello,
> >  The alertif statement is the one that seems to be the one that would
> > fit the best. I need the candle to close above/below the trendline
> > first before the alert is sent. Has anyone developed such a code for
> > trendlines they wouldn't mind sharing, please? Thank you for any and
> > all help.
> > 
> > Kindest regards,
> > 
> > Tim
> > 
> > 
> > 
> > 
> > 
> > --- In [email protected], "Tim" <raven4ns@> wrote:
> > >
> > > Hello,
> > >  I have found an Auto Trendline Dll which works great and is exactly
> > > what I was looking for, thanks to GP. How can I set up an alert to
> > > sound and record in the alert output log whenever a stock
crosses the
> > > trendline and closes above or below it? It would be on the first
close
> > > and not subsequent closes above or below the trendline. Thank
you for
> > > any and all help.
> > > 
> > > Kindest regards,
> > > 
> > > 
> > > Tim
> > >
> >
>


Reply via email to