Drag Point Tools ?

TeeChart for ActiveX, COM and ASP
Post Reply
Kabal
Newbie
Newbie
Posts: 19
Joined: Mon Mar 13, 2006 12:00 am

Drag Point Tools ?

Post by Kabal » Wed Apr 05, 2006 11:48 am

Hello Support Team,

I added in chart the DragPoint Tools. I want to process event of the end of drag. How to make it ?

Best regards, Rustam.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Apr 05, 2006 11:59 am

Hi Rustam,

An specific event for that doesn't exist but you can easily achieve that by using TeeChart's OnMouseUp event and the series Clicked method as shown here:

Code: Select all

Private Sub TChart1_OnMouseUp(ByVal Button As TeeChart.EMouseButton, ByVal Shift As TeeChart.EShiftState, ByVal X As Long, ByVal Y As Long)
    If (TChart1.Series(0).Clicked(X, Y) <> -1) Then
        MsgBox "Point Dragged!"
    End If
End Sub
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Kabal
Newbie
Newbie
Posts: 19
Joined: Mon Mar 13, 2006 12:00 am

Post by Kabal » Wed Apr 05, 2006 1:44 pm

narcis wrote: An specific event for that doesn't exist but you can easily achieve that by using TeeChart's OnMouseUp event and the series Clicked method as shown here:
Alas! It not quite that. I have event each time when the cursor is crossing the series line.

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Post by Narcís » Wed Apr 05, 2006 2:00 pm

Hi Kabal,

It works fine here, it only fires after a series point has been clicked and the mouse button is released. Are you sure that you didn't implement the code in the OnMouseMove event instead of OnMouseUp?
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Kabal
Newbie
Newbie
Posts: 19
Joined: Mon Mar 13, 2006 12:00 am

Post by Kabal » Thu Apr 06, 2006 3:37 am

narcis wrote:Hi Kabal,

It works fine here, it only fires after a series point has been clicked and the mouse button is released. Are you sure that you didn't implement the code in the OnMouseMove event instead of OnMouseUp?
It's not working when You have started drag from "clicked" point in the Series but have stopped drag on free region. Then Clicked return -1 however the point have been moved.

Best regards, Rustam.

Pep
Site Admin
Site Admin
Posts: 3295
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Tue Apr 11, 2006 9:52 am

Hi Rustam,

yes, in that case, if you want to control this you will have to use the OnMouseDown, OnMouseMove and OnMouseUp events checking on these ones which point was clicked when the mouse is released.

Post Reply