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. Image for the cookie policy date

ExcelSelectionMarker and griddataboundgrid

I''ve been trying to implement your example of the ExcelSelectionMarker and am not having much luck. My intent was to implement this then add the AutoFill functionality. Will this work on a GridDataBoundGrid? One thing I''ve found is that I''m using a databoundgrid, and your example has made use of the SelectionChanging event, which is not available for this type of grid. Additionally, when I run your example, I drag the mouse over multiple cells - the cells are highlighted but the border does not change around these cells, and when I release the mouse, the highlighted cells becomes unhighlighted -- basically nothing happens. It would be helpful if you could provide any examples in VB instead of C#. Thanks.

2 Replies

JW Jenny Wilson March 10, 2006 12:46 AM UTC

My apologies -- I am able to get your example to work -- user error. I do still need to know if this will work with a data bound grid however. Thanks again. >I''ve been trying to implement your example of the ExcelSelectionMarker and am not having much luck. My intent was to implement this then add the AutoFill functionality. > >Will this work on a GridDataBoundGrid? > >One thing I''ve found is that I''m using a databoundgrid, and your example has made use of the SelectionChanging event, which is not available for this type of grid. > >Additionally, when I run your example, I drag the mouse over multiple cells - the cells are highlighted but the border does not change around these cells, and when I release the mouse, the highlighted cells becomes unhighlighted -- basically nothing happens. > >It would be helpful if you could provide any examples in VB instead of C#. > >Thanks.


AD Administrator Syncfusion Team March 10, 2006 09:39 AM UTC

Hi Wilson, The Excel like selection behavior illustrated in the ExcelSelectionMarker sample can also be implemented in the GridDataBoundGrid. In that sample the SelectionChanging event is handled to avoid selecting the first column and, is not needed to handle this event to get excel like selection behavior. But, still this event is there in the GridDataBoundGrid under the GridModel.   this.gridDataBoundGrid1.Model.SelectionChanging += new GridSelectionChangingEventHandler(Model_SelectionChanging); To get the Autofill functionality, the ExcelMarkerMouseController from the ExcelSelectionMarker sample can be used which, enables dragging at the bottom right corner of a cell and on release you can get the affected cell range. At this point you have to affect copying into the range using whatever algorithm you want to use to fill the expanded range. Best Regards, Calvin.

Loader.
Live Chat Icon For mobile
Up arrow icon