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

FibonacciRetracement template doesn't change

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

    FibonacciRetracement template doesn't change

    Hello,

    I have created, manually, two templates for fibonacciretracements.

    On my indicator I , programatically, draw fibos normally but under certain circumstances I need to change the template that the fibo is using. For some reason this does nothing.
    My code to create the fibonacciretracements is as follows:

    string template = "ShortBig";
    Draw.FibonacciRetracements(this, "Fibo_" + miFibo.Id, true, barsAgoStart, miFibo.High, barsAgoFinish, miFibo.Low, false, template);

    Where template is a string containing the template name exactly as I created manually. This works great.

    If I use the same line again but with template = "ShortSmall" with the fibo with that Tag already existing it does nothing.

    Is there a specific way to change the template of a fibonacciretracement? or am I missing something?

    #2
    Hello Catalon,

    A drawing tool template is applied when the object is created. It would not be possible to apply a template to an existing object. You would need to remove the old object and create a new object with a new tag name for the template to be applied.

    Or you can change individual colors / price levels of the existing object.
    Chelsea B.NinjaTrader Customer Service

    Comment


      #3
      I see, thank you.

      Comment


        #4
        Originally posted by NinjaTrader_ChelseaB View Post
        Hello Catalon,

        A drawing tool template is applied when the object is created. It would not be possible to apply a template to an existing object. You would need to remove the old object and create a new object with a new tag name for the template to be applied.

        Or you can change individual colors / price levels of the existing object.
        Hi, sorry to re-open this but I have a following problem to the issue above.
        I have read the Considerations For Compiled Assemblies in the NT8 documentation but I don't seem to understand it. My problem is that I have a string parameter which is the name of the template that I wish to apply to the fibonacciretracement when I programatically create it. When I do this on the compiled assembly it doesn't load the pricelevels of the template correctly but it does load all other customization.

        What do I have to do to assign a template which has already been created (manually) to the fibonacciretracement loading all customization including the pricelevels , which as I said comes from the template created manually.

        Sorry for my English.


        Thank you.

        Comment


          #5
          Hello Catalon,

          Thank you for the note.

          I was able to get my compiled test script to work. Please see the attached test indicator. I have templates named "Levels1" and "Levels2". Levels1 draws first, then after that bar closes, Levels2 template is drawn. Place the file within your Documents\NinjaTrader 8\bin\Custom\Indicators directory and compile>add ChangeDrawTest to a 10 second chart.

          Please let me know if this does not resolve your inquiry.
          Attached Files
          Chris L.NinjaTrader Customer Service

          Comment


            #6
            Originally posted by NinjaTrader_ChrisL View Post
            Hello Catalon,

            Thank you for the note.

            I was able to get my compiled test script to work. Please see the attached test indicator. I have templates named "Levels1" and "Levels2". Levels1 draws first, then after that bar closes, Levels2 template is drawn. Place the file within your Documents\NinjaTrader 8\bin\Custom\Indicators directory and compile>add ChangeDrawTest to a 10 second chart.

            Please let me know if this does not resolve your inquiry.
            Sorry but it doesn't work. I've run some tests and If I run your adon-on directly there are no problems. Once I export as protected compiled assembly (or not protected) and import again (I tried 2 different computers) then it doesn't load the pricelevels as customized on the template.

            This only occurs as I've said if I export as compiled assembly and then import it into any computer. If I export normally without compiling there is no problem either.

            Comment


              #7
              Sorry for bump, I can't figure this problem out. Any Ideas?

              Comment


                #8
                Hello Catalon,

                Thanks for the reply.

                Upon revisiting my test script, the script does use the first template but does not properly remove and add the Levels2 template. I will test further and let you know what I find.

                Thanks in advance for your patience.
                Chris L.NinjaTrader Customer Service

                Comment


                  #9
                  Ok, thanks for your response and for looking into it

                  Comment


                    #10
                    Originally posted by NinjaTrader_ChrisL View Post
                    Hello Catalon,

                    Thanks for the reply.

                    Upon revisiting my test script, the script does use the first template but does not properly remove and add the Levels2 template. I will test further and let you know what I find.

                    Thanks in advance for your patience.
                    Hello ChrisL, have you been able to look into this?

                    Comment


                      #11
                      Hello Catalon,

                      Thanks for the reply.

                      I have submitted this issue to our development team for review. It could take 2-3 business days for a response from them.

                      Thanks in advance for your patience.
                      Chris L.NinjaTrader Customer Service

                      Comment

                      Latest Posts

                      Collapse

                      Topics Statistics Last Post
                      Started by Kaledus, Today, 01:29 PM
                      1 response
                      6 views
                      0 likes
                      Last Post NinjaTrader_Jesse  
                      Started by frankthearm, Yesterday, 09:08 AM
                      13 responses
                      45 views
                      0 likes
                      Last Post frankthearm  
                      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
                      55 views
                      0 likes
                      Last Post PhillT
                      by PhillT
                       
                      Started by yertle, Yesterday, 08:38 AM
                      8 responses
                      37 views
                      0 likes
                      Last Post ryjoga
                      by ryjoga
                       
                      Working...
                      X