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.

Disabling Multiple cell drag drop in Grid Control

Thread ID:





76725 Sep 20,2008 07:02 AM Sep 22,2008 01:07 AM Windows Forms 1
Tags: GridControl
Ankit Thakkar
Asked On September 20, 2008 07:02 AM

Hi there,
I am usig Drag and Drop functionality provided by Grid Control. But it by default allows me to drag multiple cells. Is there any property available to disable multi cell drag drop? i want to have only single cell drag and drop for my application.

Awaiting your response.

Many Thanks,

Jisha Joy [Syncfusion]
Replied On September 22, 2008 01:07 AM

Hi Ankit,

We appreciate your interest in Syncfusion Products.

Disabling Multiple cell drag drop in Grid Control

This can be achieved by handling the QueryCanOleDragRange event and can check for e.Range.Width and e.Range.Height. Please refer the code:

gridControl1.AllowDrop = true;
gridControl1.QueryCanOleDragRange += new GridQueryCanOleDragRangeEventHandler(gridControl1_QueryCanOleDragRange);

void gridControl1_QueryCanOleDragRange(object sender, GridQueryCanOleDragRangeEventArgs e)
if (e.Range.Width >1 || e.Range.Height>1)
e.Cancel = true;

Please try this and let me know if this helps.



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.