• 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

Toolbar Buttons

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

    #16
    Thanks for your comments.Buttons always work with tool bar.this is a strategy not an indicator.But may be possible to modify in future.

    Comment


      #17
      Hi I was wondering if anybody was having issues with this strategy in NT 7.01000.6?

      I started the strategy, immediately turned off the auto-trading so that the "Manual" was in red and then I turned off long entries as well. Then the strategy started to taking long trades on it's own.

      Is this an issue that only I'm seeing?

      Comment


        #18
        Hi snaphook,

        I've been trying to move your buttons and separtors to a 2nd toolbar (just below the Ninja toolbar). But unfortunately, I cannot get it to work.

        I've been told that I need to add:

        Toolstrip ts = new ToolStrip();
        ChartControl.Controls.Add(ts);

        I just can't figure out where to place this code? Do you know how to do it in your code? Any assistance you could provide would be most greatly appreciated.

        fosch

        Comment


          #19
          I've never tried to add a new toolbar.

          I am not really a programmer, but a follower of examples and a copy cat and sometimes it is tough to follow some of the examples on the net and translate them to NT.

          I'm not sure how, or if, you can do it. I think I read a post by one of the NT guys, wonder why there are no gals, that NT was written in such a manner that you can not add new toolbars.

          good luck.

          Comment


            #20
            Thanks Snaphook,

            Yeah. I've tried many permutations. I actually am able to add a toolbar, but it is always above the Ninja Toolbar, and I cannot add buttons to it. Also, once added. I cannot get rid of it like I can the buttons. Real bummer.

            Thanks for your reply.

            fosch

            Comment


              #21
              What do you add to create a new toolbar. I'd be interested.

              Comment


                #22
                All I did was add,

                private System.Windows.Forms.ToolStrip ts2 = new ToolStrip();

                to #region Variables

                and then,

                ChartControl.Controls.Add(ts2);

                to OnStartUp()

                Comment


                  #23
                  @snaphook

                  Thanks for sharing toolbar code for buttons.

                  Can it be used as is or it needs addition of actions for trade managment after OnClick event?

                  When I place it on a chart, it spontaneously opens orders.

                  Comment


                    #24
                    It needs something added to trigger a trade such as a MA crossover. Right now it places trades if Close = High or Low of Bar. I put these in as dummy requirements for illustration only. Check lines 163 and 165.

                    Edit: I just noticed an oversight.

                    Lines 177 should be:
                    if(trade.Contains("L") && btnLongEntry.Text == "Enter Long")

                    and 184 should be:
                    if(trade.Contains("S") && btnShortEntry.Text == "Sell Short")
                    Last edited by snaphook; 09-13-2011, 05:50 AM.

                    Comment


                      #25
                      Thanks for all this work, guys!

                      Does anyone know if a button on the chart panel could be made click-draggable around the panel? Or can it only be in one fixed position?

                      Bryan
                      cassb
                      NinjaTrader Ecosystem Vendor - Logical Forex

                      Comment


                        #26
                        How does one drag a button w/o clicking it?

                        I suspect if you put a button in a dialog form, set it to be on top, you could then move it around anywhere you'd like. Take a look at my Notes Panel or WorkspaceChanger in NT7 Indies for examples of opening a form.
                        Last edited by snaphook; 09-27-2011, 07:23 AM.

                        Comment

                        Latest Posts

                        Collapse

                        Topics Statistics Last Post
                        Started by ct, Today, 08:13 PM
                        0 responses
                        4 views
                        0 likes
                        Last Post ct
                        by ct
                         
                        Started by Lumbeezl, Today, 05:17 PM
                        0 responses
                        6 views
                        0 likes
                        Last Post Lumbeezl  
                        Started by wishing, Today, 03:33 PM
                        0 responses
                        10 views
                        0 likes
                        Last Post wishing
                        by wishing
                         
                        Started by ATMtrader0001, Today, 01:48 PM
                        1 response
                        8 views
                        0 likes
                        Last Post NinjaTrader_PaulH  
                        Started by RandanAL, Yesterday, 05:13 PM
                        1 response
                        12 views
                        0 likes
                        Last Post NinjaTrader_Kate  
                        Working...
                        X