PureBytes Links
Trading Reference Links
|
Take a look at the code for the TrendLine-Automatic indicator that came
with TradeStation for an example.
The trendline drawing functions are undocumented in the manuals I have but
are pretty well documented in the on-line "Function Help".
Each trendline gets an ID number as it is drawn so it should be easy to
delete only the trendline with the ID number you want to delete. In the
on-line help for the "TL_New" function, the ID number is called Value1. You
create a new trendline with the statement:
Value1 = TL_New(....);
You use this number (Value1) at any later time to refer to that trendline
in the other trendline functions.
Bob Fulks
At 4:28 AM -0400 6/2/98, Garry & Joanna wrote:
>
>I haven't been using TS long and am trying to write an indicator to do the
>following:-
>Identify swing highs (done in an array capturing swing hi, barnumber, date
>and time)
>Plot a trendline horizontally across that swing high (done & extended right)
>If that swing high is subsequently taken out by a higher high I want to
>delete that trend line (and only that trend line). All I have managed to
>do so far is delete all the trend lines if I attempt to delete a specific
>line. So I end up with all or nothing.
>Alternately, if the swing high is subsequently taken out by a higher high,
>then I want to end that trend line on the bar that makes the higher high.
>Can anyone help me with ideas on how to do this, or suggest anywhere that
>I might look for ideas.
>Any help much appreciated
|