Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

initializing variable

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    initializing variable

    Hello,

    Should I initializing a variable below class or in State == State.Configure?

    I noticed that the strategy sample and the indicator sample seem to be different


    #2
    Hello jetheil2,

    Thank you for your note.

    Which samples are you referring to that are different? If you can provide a link that would be helpful.

    Generally I would recommend instantiating variables at the class level between the Class declaration and OnStateChange, and assigning default values in State.SetDefaults.

    Thanks in advance; I look forward to assisting you further.

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by NullPointStrategies, Yesterday, 05:17 AM
    0 responses
    75 views
    0 likes
    Last Post NullPointStrategies  
    Started by argusthome, 03-08-2026, 10:06 AM
    0 responses
    146 views
    0 likes
    Last Post argusthome  
    Started by NabilKhattabi, 03-06-2026, 11:18 AM
    0 responses
    79 views
    0 likes
    Last Post NabilKhattabi  
    Started by Deep42, 03-06-2026, 12:28 AM
    0 responses
    50 views
    0 likes
    Last Post Deep42
    by Deep42
     
    Started by TheRealMorford, 03-05-2026, 06:15 PM
    0 responses
    54 views
    0 likes
    Last Post TheRealMorford  
    Working...
    X