A very simplistic code sample is below to demonstrate the problem. What I am expecting is that a Journal line is written upon a parameter value being changed in the FT2 -> List of Indicators -> (Select Indicator Name) -> Edit -> (Change a value) -> Apply -> Open Chart / X
Instead nothing happens.
I am using FT2 v.2.9.3 and Lazarus v.1.0.6 (full clean builds).
Any help & assistance is greatly appreciated.
Code: Select all
//---------------------------------------------------------------------------
// FT2_z1
//---------------------------------------------------------------------------
library FT2_z1;
uses
IndicatorInterfaceUnit, TechnicalFunctions;
var
// External variables
SomeBoolean: boolean = true;
SomeInteger: integer = 10;
//---------------------------------------------------------------------------
// Initialization procedure
//---------------------------------------------------------------------------
procedure Init; stdcall;
begin
// indicator configuration
IndicatorShortName('FT2_z1');
SetOutputWindow(ow_ChartWindow);
// external parameter definition
AddSeparator('Common');
RegOption('Some Boolean', ot_Boolean, SomeBoolean);
RegOption('Some Integer', ot_Integer, SomeInteger);
end;
//---------------------------------------------------------------------------
// Deinitialization procedure (can be omitted)
//---------------------------------------------------------------------------
procedure Done; stdcall;
begin
// do nothing
end;
//---------------------------------------------------------------------------
// On parameters change procedure (can be omitted)
//---------------------------------------------------------------------------
procedure OnParametersChange; stdcall;
begin
Print('OnParametersChange');
end;
//---------------------------------------------------------------------------
// Calculation of a single bar
//---------------------------------------------------------------------------
procedure Calculate(index: integer); stdcall;
begin
// do nothing
end;
exports
// these procedures should be declared as external
Init, Done, OnParametersChange, Calculate;
end.