[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problems with "Update at every tick" in ts2000i



PureBytes Links

Trading Reference Links

At 03:31 PM 6/2/2004, you wrote:

>{This should execute only on the first bar of the day}
>if(Date <> Date[1]) then begin

This will execute on every tick of the first bar of the day if the indicator is set to update on every tick.

Try this:

---------------------------------
Vars: DaInit(TRUE);

if Date <> Date[1] then begin
   if DaInit then begin
      DaInit = FALSE;
      <your code here>
   end;
end else Dainit = TRUE;
---------------------------------

You can use the same trick to make any code execute only one time on a new bar.

Bob Fulks