• If this is your first visit, you will have to register before you can post. To view messages, please scroll below and select the forum that you would like to visits. Questions? Be sure to check out the Forum FAQ.

Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

Programatically create and control charts in NinjaScript

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

    Programatically create and control charts in NinjaScript

    Is it possible to programatically create and control charts in NinjaScript? I know this will almost certainly be unsupported, but unsupported is better than not possible.

    Hopefully, in NT8, this will be supported. Meanwhile, an unsupported method in NT7 would be much appreciated, all caveats being well understood.

    Thanks.

    #2
    Hello jeronymite,

    You would not be able to create a chart using NinjaScript, but you can control a chart using NinjaScript to a certain degree.

    You may change the background, Candleoutline, BarColor, etc... using NInjaScript that is supported. Here is a link to our Help Guide that goes over some of the Drawing methods that you can use to control a chart.
    http://www.ninjatrader.com/support/h...ml?drawing.htm

    There are more ways you may control a chart by overriding the plot method but this would be unsupported. Here is a good link to a thread that goes over some ways you can also control a chart.
    http://www.ninjatrader.com/support/f...ad.php?t=23979
    JCNinjaTrader Customer Service

    Comment


      #3
      Thanks.

      I am creating a front-end trading application for a specific financial environment. What I really need is the ability to:
      • Create a chart with specific properties (as per the Properties Grid when creating a chart manually)
      • Control the chart:
        • Change the properties of the chart, as per the toolstrip of the chart; e.g. timeframe, adding/removing indicators, etc
        • Re-scale the axes
        • Etc (basically anything one can do manually, I want to be able to do programmatically)

      • Delete the chart

      Any unsupported methods in NT7 to do these things would be greatly appreciated!

      Making it possible to do these things in a supported manner in NT8 would be extremely desirable!

      Thanks for any further assistance.

      Comment


        #4
        Update?

        It's nearly 1.5 years since I posted this enquiry. (How time flies when you're having fun!)

        Just wondering if anyone has discovered any (very unsupported, no doubt) magic in the meantime to do any or all of this? Primarily the ability to create a chart with a given instrument and time-frame is required, but the other actions are highly desirable.

        Also, here's hoping it will all be possible and supported in NT8.

        Thanks!

        Comment


          #5
          Originally posted by jeronymite View Post
          It's nearly 1.5 years since I posted this enquiry. (How time flies when you're having fun!)

          Just wondering if anyone has discovered any (very unsupported, no doubt) magic in the meantime to do any or all of this? Primarily the ability to create a chart with a given instrument and time-frame is required, but the other actions are highly desirable.

          Also, here's hoping it will all be possible and supported in NT8.

          Thanks!
          Whereas you cannot really do that easily through NinjaScript, have you considered that while you wait, you could do it by scripting from Windows itself?

          https://www.autoitscript.com/site/autoit/

          Not very neat, I know, but it does work.

          Comment


            #6
            Thanks!

            Many thanks, koganam! Very useful indeed.

            Comment


              #7
              On a similar note is it possible to programmatically switch the focus to a another open chart and perhaps enable a strategy?

              Thanks in advance.

              Comment


                #8
                Originally posted by Hank_R View Post
                On a similar note is it possible to programmatically switch the focus to a another open chart and perhaps enable a strategy?

                Thanks in advance.
                AutoIT should be able to do that, yes.

                Comment


                  #9
                  Originally posted by jeronymite View Post
                  It's nearly 1.5 years since I posted this enquiry. (How time flies when you're having fun!)

                  Just wondering if anyone has discovered any (very unsupported, no doubt) magic in the meantime to do any or all of this? Primarily the ability to create a chart with a given instrument and time-frame is required, but the other actions are highly desirable.

                  Also, here's hoping it will all be possible and supported in NT8.

                  Thanks!
                  There are plenty of custom price ladders and stuff out there, so you should be able to use your own charting package. At that point you just might as well develop your own software? Why get stuck with an albatross over your head. NT upgrades would break all the custom code.

                  Comment


                    #10
                    Originally posted by koganam View Post
                    AutoIT should be able to do that, yes.
                    As well as AutoHotkey, see http://ahkscript.org.

                    I think AutoHotkey and AutoIt share a common lineage ...

                    Search for AutoHotkey on Big Mike's for some interesting ideas.

                    Comment

                    Latest Posts

                    Collapse

                    Topics Statistics Last Post
                    Started by Miguel_88, Today, 06:41 PM
                    0 responses
                    5 views
                    0 likes
                    Last Post Miguel_88  
                    Started by spikeruk, Today, 01:49 PM
                    1 response
                    11 views
                    0 likes
                    Last Post NinjaTrader_PaulH  
                    Started by Yandychang, Today, 02:16 PM
                    5 responses
                    17 views
                    0 likes
                    Last Post NinjaTrader_Jesse  
                    Started by priceisking, Today, 01:16 PM
                    2 responses
                    8 views
                    0 likes
                    Last Post priceisking  
                    Started by kashyapjdave, 03-23-2017, 12:12 AM
                    11 responses
                    1,959 views
                    0 likes
                    Last Post forextrader2003  
                    Working...
                    X