PDA

View Full Version : Problems accessing TickSize


gomifromparis
10-11-2009, 09:38 AM
Hi,

When I try to access TickSize in Initialize method, using for instance Print(TickSize)
I get exception

"Failed to call method 'Initialize' for indicator 'xx': 'BarsInProgress' property can not be accessed from within 'Initialize' method"

NinjaTrader_Ray
10-11-2009, 11:54 AM
Hi,

When I try to access TickSize in Initialize method, using for instance Print(TickSize)
I get exception

"Failed to call method 'Initialize' for indicator 'xx': 'BarsInProgress' property can not be accessed from within 'Initialize' method"

This is due to a changed implementation to accomodate multi-series strategies.. You could try something like this:


if (Instrument != null)
Print(Instrument.MasterInstrument.TickSize);

gomifromparis
10-11-2009, 12:08 PM
thanks, it works.