- The custom bar type will be shipped in a securely compiled assembly also containing a "helper" indicator (HelperIndicator) that has a call to the VendorLicense() method in its Initialize() method.
- If HelperIndicator's VendorLicense check passes OK, a public property of the "helper" indicator, LicensedOk, will be set to TRUE.
- The custom bar type needs to be able to check the value of this public property of HelperIndicator. I am approaching this as follows:
- Add reference in the custom bar to NinjaTrader.cbi.
- Add the following variable in the custom bar:
Code:
private NinjaTrader.Indicator.IndicatorBase _helper = null;
- Add a firstline within the Add() method of the custom bars, something along the lines of .
Code:
(NinjaTrader.Indicator.IndicatorBase) _helper = NinjaTrader.Indicator.IndicatorBase.HelperIndicator.;
... etc ...
However, I am getting a compilation error...
Comment