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!
See more
See less

Partner 728x90

Collapse

Remove DrawObject error

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

    Remove DrawObject error

    I am getting a error on the log file. I am trying to remove the object before drawing it. This is what I have
    I am looping my nGraphicCount to a maximum of 200 in order not to hog down the system.

    //check and remove object
    if(DrawObjects["circ" + nGraphicCount.ToString()] != null)
    RemoveDrawObject("circ" + nGraphicCount.ToString());

    //DrawObject
    Draw.Rectangle(this,"circ"+nGraphicCount.ToString( ),false,Time[1],Close[1],Time[5],High[1],pEllipseUpColor,pEllipseUpColor,nEllipseOpacity);

    I do not know how to rectify this.


    #2
    Hello ballboy11,

    The message means that whatever tagname you have chosen for the drawing object, cannot be used for another type of drawing object.

    If you draw with the name "circ"+nGraphicCount.ToString( ), then no other drawing objects can use this tag name.
    Chelsea B.NinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by llanqui, Today, 08:32 AM
    1 response
    5 views
    0 likes
    Last Post llanqui
    by llanqui
     
    Started by lollers, Yesterday, 03:26 AM
    1 response
    52 views
    0 likes
    Last Post lollers
    by lollers
     
    Started by Salahinho99, 05-05-2024, 04:13 AM
    7 responses
    62 views
    0 likes
    Last Post Salahinho99  
    Started by knighty6508, 05-10-2024, 01:20 AM
    4 responses
    29 views
    0 likes
    Last Post knighty6508  
    Started by OllieFeraher, 05-09-2024, 11:14 AM
    6 responses
    19 views
    0 likes
    Last Post OllieFeraher  
    Working...
    X