I manually added the variable in #region variables like this:
privateint BollThresh = 20;
and added a reference in #region properties near the end of the file like this.
[Description("")]
[Category("Parameters")]
publicint BollThresh
{
get { return BollThresh; }
set { BollThresh = Math.Max(1, value); }
}
But the compiler does not like seeing both present. It barks at the properties entry and says "The type 'NinjaTrader.Strategy.LongHammerTrailingStop' already contains a definition for 'BollThresh' Strategy\LongHammerTrailingStop.cs 83 12."
But if I omit the properties entry (which compiler passes the run with), then I won't see the variable listed as an adjustable option.
Note that this code file doesn't have the Wizard XML at the end of it. Is this absolutely necessary to create user input variables? Does that require I create a hollow shell with my named variables the wizard that creates the XML, that I then paste my procedures in?
Any quick and fast workarounds for nonwizard work?
Comment