Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

How to change/set ChartPanel.(X/Y/W/H) via code?

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

    How to change/set ChartPanel.(X/Y/W/H) via code?

    Hello,

    I'm trying to change an existing chart panel's X/Y/W/H values via code, but I keep running into the following error:

    Property or Indexer "NinjaTrader.Gui.Chart.ChartPanel.Y" cannot be assigned to -- it is read only
    my understanding of this error is that normally I would have to create another instance of what ever I'm trying to assign a value to, and then give that instance the value. Unless, I'm not clear on this, I do not see how that is a viable option in this case. What I'm trying to do is resize the height and alter the Y coordinate of an indicator's chart panel.

    Any idea how this can be done?


    thank you in advance!


    #2
    Hello Gubbar924,

    Thank you for writing in.

    ChartPanel.Y/X/W/H are values you can get but not set. There is no supported way to resize the height of a chart panel through code in NT8.

    Please let us know if you need further assistance.
    Alan P.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by Mindset, 04-21-2026, 06:46 AM
    0 responses
    49 views
    0 likes
    Last Post Mindset
    by Mindset
     
    Started by M4ndoo, 04-20-2026, 05:21 PM
    0 responses
    69 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by M4ndoo, 04-19-2026, 05:54 PM
    0 responses
    36 views
    0 likes
    Last Post M4ndoo
    by M4ndoo
     
    Started by cmoran13, 04-16-2026, 01:02 PM
    0 responses
    96 views
    0 likes
    Last Post cmoran13  
    Started by PaulMohn, 04-10-2026, 11:11 AM
    0 responses
    59 views
    0 likes
    Last Post PaulMohn  
    Working...
    X