We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

IMouseEventReceiver

Thread ID:

Created:

Updated:

Platform:

Replies:

68370 Sep 19,2007 10:34 AM Sep 20,2007 04:52 PM Windows Forms 2
loading
Tags: Diagram
Gianni Rossi
Asked On September 19, 2007 10:34 AM

Hello,
i'd like to create a custom tool and i'm following the logic explained in the Knowledge Base. I'd like to ask where i can find the IMouseEventReceiver class that must be inherited by the custom tool one.

Thanks

Gianni Rossi
Replied On September 19, 2007 10:40 AM

I've read in the forum that the interface class should be defined as Syncfusion.Windows.Forms.Diagram.IMouseEventReceiver
but i cannot find it here in my installation.
Has something changed in the lastest version of the component?

J.Nagarajan [Syncfusion]
Replied On September 20, 2007 04:52 PM

Hi GTec,

Thanks for your interest in Syncfusion products.

IMouseEventReceiver interface is no longer valid in v5.2. You can use ProcessMouseDown, ProcessMouseMove and ProcessMouseUp methods for firing events in the customtool.

You have to derive a Tool class to create a custom tool. After creating a custom tool you have to register it in Diagram Controller. Please refer to the following code snippet

[C#]

//To activate the LineTool in MainForm.cs

MyLineTool linetool = new MyLineTool(this.diagram1.Controller);
this.diagram1.Controller.RegisterTool(linetool);
this.diagram1.Controller.ActivateTool(linetool);


I have attached the sample that demonstrates this completely. You can download the sample from the following page.

http://websamples.syncfusion.com/samples/Diagram.Windows/F68370/main.htm

Please refer to the sample and let me know if this helps.

Regards,
Nagaraj

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;