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.

old DisplayMember / ValueMember topic into filter combo box.

Thread ID:

Created:

Updated:

Platform:

Replies:

8368 Nov 4,2003 04:34 AM Dec 13,2005 01:18 PM Windows Forms 4
loading
Tags: GridControl
Administrator [Syncfusion]
Asked On November 4, 2003 04:34 AM

Hi, my gridboundcolumn with comboboxes obtains its Display- and ValueMember from an external table. The DisplayMember is shown and the ValueMember is written (This works fine). In the filterbar combobox only the ValueMember is displayed now, though, this isn't so good. In the attachement can be seen being filled like the filter comboboxes. Aggravating a predefined data view filter still is additionally that you must take into account. Gives it a solution,to include the DisplayMember of the comboboxes, into the filterbar combobox? greetings markus

Administrator [Syncfusion]
Replied On November 4, 2003 06:34 AM

You can handle this problem by deriving GridFilterBar and overriding WireGrid and GetFilterFromRow. Attached is a sample that has modified our shipping FilterBar sample to use such a derived filterbar. In this sample, choose the Orders table, and the Employees column in that table uses a foreign key combobox. Note in addition to using the derived GridFilterBar class, the FormatGrid call was moved ahead of call filterbar.WireGrid so the FilterBar could recognize the foreign key combobox column.

Administrator [Syncfusion]
Replied On November 6, 2003 03:07 AM

Hi Clay, your notes have helped me along very much. To hold the filter actual, I have filled the filter table in CurrentCellShowingDropDown manually till now. The Workaround to the visualization of the displaymembers described by you works very well (the CurrentCellShowingDropDown Eventhandler is now empty). A weakness still has the solution, though. Is it possible with the workaround described by you to keep the announced contents of the filter combo boxings current? Changes in the data area of the Grids aren't shown when filterbox is showing dripdown. I am sure, you also have a solution for this problem handily. greetings markus

Administrator [Syncfusion]
Replied On November 6, 2003 03:46 AM

Exactly what do you mean by "contents of the filter combo boxings current"? Say you have a value member '13' with display member 'abc' for a particular cell in the grid. Then the user types 'xyz' in the cell. Does this mean that valuemember '13' is now associated with 'xyz' and 'abc' is no longer in the drop list. Or, does it mean 'xyz' should be added to the droplist. If 'xyz' is to be added, how is its associated new value member to be determined. Also, should these changes be pushed back to some ADO.NET datasource, so the next the application is run, the new display-value member pair is available from the foreign key datasource? I think these things can be done. You would handle an event like maybe CurrentCellValidating, and if the new value ( grid.CurrentCell.Renderer.ControlText) is not in the combobox list, then do whatever you need to do to add it. What you need to do will depend upon the answers to the above questions.

Administrator [Syncfusion]
Replied On December 13, 2005 01:18 PM

Is there a new solution to this problem sincer the release of version 3.3? I am refereing to the problem highlighted in the forum link below where the filter displays the value memeber instaed of the display memeber? http://64.78.18.34/Support/Forums/message.aspx?MessageID=8368 >Hi, >my gridboundcolumn with comboboxes obtains its Display- and ValueMember from an external table. >The DisplayMember is shown and the ValueMember is written (This works fine). > >In the filterbar combobox only the ValueMember is displayed now, though, this isn''t so good. > >In the attachement can be seen being filled like the filter comboboxes. > >Aggravating a predefined data view filter still is additionally that you must take into account. > >Gives it a solution,to include the DisplayMember of the comboboxes, into the filterbar combobox? > >greetings markus

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.

;