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.

Getting error when trying to set the dropdownrows in Grouping Grid.

Thread ID:

Created:

Updated:

Platform:

Replies:

16982 Jul 28,2004 09:45 AM Jul 29,2004 10:39 AM Windows Forms 3
loading
Tags: Grouping
Bhandhavi Sangaru
Asked On July 28, 2004 09:45 AM

Private Sub myGroupingGrid_TableControlCurrentCellShowingDropDown(ByVal sender As Object, ByVal e As Syncfusion.Windows.Forms.Grid.Grouping.GridTableControlCurrentCellShowingDropDownEventArgs) Handles myGroupingGrid.TableControlCurrentCellShowingDropDown Dim grid As GridControlBase = CType(sender, GridControlBase) Dim cc As GridCurrentCell = CType(grid.CurrentCell, GridCurrentCell) Dim cr As GridDropDownGridListControlCellRenderer = CType(cc.Renderer, GridDropDownGridListControlCellRenderer) CType(cr.ListControlPart, GridDropDownGridListControlPart).DropDownRows = 10 End Sub I am using the above code to set the number of dropdownrows of my GridListControl in a GroupingGrid. I used the same code for GridListControl in GridDataboundGrid and it worked. I am getting an invalid Cast at line Dim grid As GridControlBase = CType(sender, GridControlBase) Please help! Thanks, Bhandhavi.

Administrator [Syncfusion]
Replied On July 29, 2004 08:47 AM

Hi Bhandhavi, the sender will be of type GridGroupingControl. Use Dim grid As GridControlBase = e.Inner.TableControl instead. Stefan

Administrator [Syncfusion]
Replied On July 29, 2004 09:31 AM

I meant Dim grid As GridControlBase = e.TableControl Stefan

Bhandhavi Sangaru
Replied On July 29, 2004 10:39 AM

Stefen, Thanks a lot. It worked perfectly. Bhandhavi.

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.

;