But I'd also like to allow the user to set it manually if they don't want to use the default. So if they enter 0 in the Length input, it will auto calc. If they put 500, it will make Length 500.
I can do the check in OnBarUpdate, but only need to do it if they change it so that seems like a lot of unnecessary work.
Where can I put something like this so that it will only calculate once, but wont change the user input?
if ( Length == 0) Length = 1000 / BarsPeriod.Value;
thanks

Comment