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

Strategy Drawing

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

    Strategy Drawing

    Hello Everyone,

    I just created a strategy that draws arrows for short and for long conditions.
    My Problem is that I only get the last 2 signals on the chart and not the rest of the historicals.

    Can you thing of something I did wrong ?

    Thanks

    John

    #2
    Strategy settings need to be changed ?
    Attached Files

    Comment


      #3
      Hello John,

      If the tag name is unique each time the draw method is called a new object is created, if the tag name is re-used the existing object is moved or updated and no new objects are created.

      Below is a link to a forum thread that discusses this.
      Chelsea B.NinjaTrader Customer Service

      Comment


        #4
        Hello and thank you for your reply.

        Do I have to edit the code inorder to succeed this ..because I created my strategy through the wizard.

        Thanks

        John

        Comment


          #5
          Hello Sohal,

          Thanks for your reply.

          No, you do not have to unlock the code to modify this.

          You would want to modify your settings for your Arrow Up and Arrow Down so that the Tag for each has something unique. In the below screenshots you can see that I've adjusted the Tag field so that the tag string includes the current bar number the arrow is drawn on, which keeps it separate.

          Click image for larger version

Name:	2019-03-25_0741.png
Views:	96
Size:	34.1 KB
ID:	1052531Click image for larger version

Name:	2019-03-25_0743.png
Views:	86
Size:	17.0 KB
ID:	1052532

          Here's what it looks like in the Conditions and Actions screen once set up:

          Click image for larger version

Name:	2019-03-25_0747.png
Views:	88
Size:	68.9 KB
ID:	1052533

          Please let us know if we may be of further assistance to you.
          Kate W.NinjaTrader Customer Service

          Comment


            #6
            Awesome ...Thank you !!!

            Comment

            Latest Posts

            Collapse

            Topics Statistics Last Post
            Started by PaulMohn, Today, 12:36 PM
            2 responses
            16 views
            0 likes
            Last Post PaulMohn  
            Started by Conceptzx, 10-11-2022, 06:38 AM
            2 responses
            53 views
            0 likes
            Last Post PhillT
            by PhillT
             
            Started by Kaledus, Today, 01:29 PM
            0 responses
            4 views
            0 likes
            Last Post Kaledus
            by Kaledus
             
            Started by yertle, Yesterday, 08:38 AM
            8 responses
            37 views
            0 likes
            Last Post ryjoga
            by ryjoga
             
            Started by rdtdale, Today, 01:02 PM
            1 response
            6 views
            0 likes
            Last Post NinjaTrader_LuisH  
            Working...
            X