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 SalmaTrader, 07-07-2026, 10:26 PM
    0 responses
    31 views
    0 likes
    Last Post SalmaTrader  
    Started by CarlTrading, 07-05-2026, 01:16 PM
    0 responses
    20 views
    0 likes
    Last Post CarlTrading  
    Started by CaptainJack, 06-17-2026, 10:32 AM
    0 responses
    9 views
    0 likes
    Last Post CaptainJack  
    Started by kinfxhk, 06-17-2026, 04:15 AM
    0 responses
    18 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Started by kinfxhk, 06-17-2026, 04:06 AM
    0 responses
    20 views
    0 likes
    Last Post kinfxhk
    by kinfxhk
     
    Working...
    X