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

old DisplayMember / ValueMember topic into filter combo box.

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

4 Replies

AD Administrator Syncfusion Team November 4, 2003 11:34 AM UTC

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.


AD Administrator Syncfusion Team November 6, 2003 08:07 AM UTC

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


AD Administrator Syncfusion Team November 6, 2003 08:46 AM UTC

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.


AD Administrator Syncfusion Team December 13, 2005 06:18 PM UTC

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

Loader.
Live Chat Icon For mobile
Up arrow icon