Hi,
I am attempting to create my first strategy (in Delphi).
I understand that the CreateIndicator() function requires certain parameters, such as:
IndCustomIndicator := CreateIndicator('EURJPY', 5, 'CustomIndicator', 'param1;param2;param3;etc.');
My question is this....
What part of the indicator code specifies what parameters are required when calling the indicator from within a strategy? Is it simply all values for which a RegOption statement was written in the indicator code?
Also, what value should be passed for a boolean? Assuming I wish to set the boolean value to 'TRUE', do I pass the parameter 'TRUE', or 'Yes' or perhaps '1'???
Thanks.
Steve
CreateIndicator() question
- Terranin
- Site Admin
- Posts: 833
- Joined: Sat Oct 21, 2006 4:39 pm
Re: CreateIndicator() question
dackjaniels wrote:Hi,
I am attempting to create my first strategy (in Delphi).
I understand that the CreateIndicator() function requires certain parameters, such as:
IndCustomIndicator := CreateIndicator('EURJPY', 5, 'CustomIndicator', 'param1;param2;param3;etc.');
My question is this....
What part of the indicator code specifies what parameters are required when calling the indicator from within a strategy? Is it simply all values for which a RegOption statement was written in the indicator code?
Also, what value should be passed for a boolean? Assuming I wish to set the boolean value to 'TRUE', do I pass the parameter 'TRUE', or 'Yes' or perhaps '1'???
Thanks.
Steve
You need to pass parameters in the same number and order as you can see in indicator options dialog (except styles). Boolean is coded by Yes and No.
Hasta la vista
Mike
Mike
-
- Posts: 151
- Joined: Tue Feb 24, 2009 1:03 pm
Re: CreateIndicator() question
Terranin wrote:You need to pass parameters in the same number and order as you can see in indicator options dialog (except styles). Boolean is coded by Yes and No.
Thanks for the reply Mike. The reason I asked was FT2 kept freezing on the splash screen every time I added my new strategy to the strategies folder.
Turns out I was compiling both indicators and strategies against the technicalfunctions.pas file from Examples/Indicators. I never realised there is a different technicalfunctions.pas file for compiling strategies.
I have now created separate folders for the indicator and strategy Delphi projects, each with the appropriate .pas files and it seems to work fine.
Thanks again,
Steve
Who is online
Users browsing this forum: No registered users and 32 guests