Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

MouseEventArgs

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

    MouseEventArgs

    Hello

    In NT 7 I was using the DoubleClick Event to get the double-click X and Y location with MouseEventArgs e parameter ( e.X and e.Y )

    Now with NT 8 the MouseEventArgs does not allow me to get the X and Y location anymore.
    What would be the solution to this ?

    Thanks

    #2
    Try using ChartControl.MouseDownPoint in the OnRender() when clicked.

    ref: http://ninjatrader.com/support/helpG...edownpoint.htm

    Comment


      #3
      Hello,

      Thank you Calonious for the information.

      That would be correct, on a side note, in an indicator or when this is loaded in a panel other than the panel 0, you would need to click in that panel for this to become active otherwise it may appear to not be working.

      I look forward to being of further assistance.

      Comment


        #4
        Thank you Calonious

        Works pretty well but I am doing test without any connection and I draw a different text according to the click location. The click is updating when I click on the chart ( printing the location on the output window ) but the text stays the same. I know it could come from a different problem probably the RenderTarget.DrawTextLayout method ?

        Comment


          #5
          What is the text suppose to be displaying when you click?

          Can you give a snippet of your code?

          Comment


            #6
            I found my problem. It comes from another problem.

            If I drag the chart the text changes. Is there a way to refresh the chart as soon as I click on the mouse ?

            I think It was ChartControl.Refresh in NT 7

            The text displays a market profile data. The location is giving me the profile I need to display text.
            Last edited by blar58; 10-06-2015, 11:57 AM.

            Comment


              #7
              Yes there is.

              ForceRefresh()

              Ref: http://ninjatrader.com/support/helpG...rcerefresh.htm

              Comment


                #8
                It works like a charm !

                Thanks Calonious !

                Comment

                Latest Posts

                Collapse

                Topics Statistics Last Post
                Started by Geovanny Suaza, 02-11-2026, 06:32 PM
                0 responses
                671 views
                0 likes
                Last Post Geovanny Suaza  
                Started by Geovanny Suaza, 02-11-2026, 05:51 PM
                0 responses
                379 views
                1 like
                Last Post Geovanny Suaza  
                Started by Mindset, 02-09-2026, 11:44 AM
                0 responses
                111 views
                0 likes
                Last Post Mindset
                by Mindset
                 
                Started by Geovanny Suaza, 02-02-2026, 12:30 PM
                0 responses
                575 views
                1 like
                Last Post Geovanny Suaza  
                Started by RFrosty, 01-28-2026, 06:49 PM
                0 responses
                582 views
                1 like
                Last Post RFrosty
                by RFrosty
                 
                Working...
                X