Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Storing Byte Default Value in Template

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

    Storing Byte Default Value in Template

    I have a basic question about the attached indicator. I have a byte value that I want to default to 55 and save in a template that way. As the code stands every time I add the indicator to a chart the opacityvalue byte defaults to 0. The same thing happens if I load a chart template with this indicator. Even of the template is saved with a byte value of 55 the chart template loads and the byte is back to 0. Is there a setting I can tweak to fix this? Thank you.
    Attached Files

    #2
    Hello jhowinvest,

    Thank you for your inquiry.

    It looks like you are specifying the type byte once more for Opacityshade in State.SetDefaults, which creates a new byte variable called Opacityshade that does not link with your public property.

    Upon removing the type byte from Opacityshade in State.SetDefaults, your public property is now set to 55 by default.

    Please, let us know if we may be of further assistance.
    Zachary G.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by pechtri, 06-22-2023, 02:31 AM
    10 responses
    124 views
    0 likes
    Last Post Leeroy_Jenkins  
    Started by judysamnt7, 03-13-2023, 09:11 AM
    4 responses
    59 views
    0 likes
    Last Post DynamicTest  
    Started by ScottWalsh, Yesterday, 06:52 PM
    4 responses
    36 views
    0 likes
    Last Post ScottWalsh  
    Started by olisav57, Yesterday, 07:39 PM
    0 responses
    7 views
    0 likes
    Last Post olisav57  
    Started by trilliantrader, Yesterday, 03:01 PM
    2 responses
    22 views
    0 likes
    Last Post helpwanted  
    Working...
    X