I want to create an enum parameter in the Propierties region to select the number of Take Profits to use in my strategy. For example: Number of Targets like picture 1. Once I select 1 target, I need to see 2 more parammeters, if I select 2 targets I need to see 4 parammeters more and If I selct None, I don't see any parameter.
Announcement
Collapse
Looking for a User App or Add-On built by the NinjaTrader community?
Visit NinjaTrader EcoSystem and our free User App Share!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
Have a question for the NinjaScript developer community? Open a new thread in our NinjaScript File Sharing Discussion Forum!
See more
See less
Partner 728x90
Collapse
NinjaTrader
Variable number of parameters depending on one of them.
Collapse
X
-
Variable number of parameters depending on one of them.
Hi,
I want to create an enum parameter in the Propierties region to select the number of Take Profits to use in my strategy. For example: Number of Targets like picture 1. Once I select 1 target, I need to see 2 more parammeters, if I select 2 targets I need to see 4 parammeters more and If I selct None, I don't see any parameter.2 PhotosTags: None
-
Hello lju45,
Thanks for your post.
You can create a custom typeconverter to help with this. For a reference, please see the help guide and example here: https://ninjatrader.com/support/help...r_to_custo.htm
I've also attached an example, based on a strategy, to assist. It has nothing in OnBarUpdate and is only to demonstrate functionality in the User Interface and provide a further example of the extensive coding needed to accomplish your goal.
ExampleTypeConverterusingEnum.zipPaul H.NinjaTrader Customer Service
Latest Posts
Collapse
Topics | Statistics | Last Post | ||
---|---|---|---|---|
Started by mly916, Today, 09:48 PM
|
1 response
11 views
0 likes
|
Last Post Today, 11:54 PM | ||
Started by Mikey_, Today, 09:21 PM
|
0 responses
11 views
0 likes
|
Last Post
by Mikey_
Today, 09:21 PM
|
||
Started by cre8able, Today, 05:53 PM
|
3 responses
14 views
0 likes
|
Last Post
by cre8able
Today, 09:20 PM
|
||
Started by Aryan Kumar, Today, 09:04 PM
|
0 responses
4 views
0 likes
|
Last Post
by Aryan Kumar
Today, 09:04 PM
|
||
Started by yertle, Yesterday, 05:49 PM
|
3 responses
16 views
0 likes
|
Last Post
by Mindset
Today, 08:38 PM
|
Comment