Announcement

Collapse
No announcement yet.

Partner 728x90

Collapse

OnMouseMove Signature

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

    OnMouseMove Signature

    Has the signature changed for OnMouseMove()? According to the docs ChartAnchor example http://ninjatrader.com/support/helpG...hartanchor.htm

    Code:
    public override void OnMouseMove(ChartControl chartControl, ChartPanel chartPanel, ChartScale chartScale, Point point)
    {
       if (DrawingState == DrawingState.Editing)
       {
          if (MyAnchor.IsEditing)
          {
             //if anchor is editing, update anchor point
             MyAnchor.UpdateFromPoint(point, chartControl, chartScale);
          }
       }
    }
    ...it's expecting a "Point point", however, the signature created in the editor is looking for a "ChartAnchor dataPoint" and throwing this error on this function:
    Code:
    UpdateFromPoint(point, chartControl, chartScale);

    Cannot convert type 'NinjaTrader.NinjaScript.DrawingTools.ChartAnchor' to 'System.Windows.Point'
    Last edited by funk101; 10-02-2015, 08:05 AM.

    #2
    Hello,

    Thank you for the question.

    Unfortunately the link provided did not work so I am unsure of the specific help document you are referring to. Is this the document or is it a different document you had linked? http://ninjatrader.com/support/helpG...ub=OnMouseMove

    When I created a brand new script and viewed the other pages in the help guide for this, I get the following implementation:

    Code:
    public override void OnMouseUp(ChartControl chartControl, ChartPanel chartPanel, ChartScale chartScale, ChartAnchor dataPoint)
    Instead of Point ChartAnchor is used.

    the doc I provided has the incorrect implementation, if the link you provided is not what I had, I would like to get the correct link to report that for changes.

    I look forward to being of further assistance.
    JesseNinjaTrader Customer Service

    Comment

    Latest Posts

    Collapse

    Topics Statistics Last Post
    Started by andrewtrades, Today, 04:57 PM
    1 response
    6 views
    0 likes
    Last Post NinjaTrader_Manfred  
    Started by chbruno, Today, 04:10 PM
    0 responses
    5 views
    0 likes
    Last Post chbruno
    by chbruno
     
    Started by josh18955, 03-25-2023, 11:16 AM
    6 responses
    436 views
    0 likes
    Last Post Delerium  
    Started by FAQtrader, Today, 03:35 PM
    0 responses
    7 views
    0 likes
    Last Post FAQtrader  
    Started by rocketman7, Today, 09:41 AM
    5 responses
    19 views
    0 likes
    Last Post NinjaTrader_Jesse  
    Working...
    X