Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
115
UltraWinGrid with an UltraDropDown control as a cell / column value
posted

Windows XP Pro / NetAdvantage 7.1.20071.40 / Windows Forms Application / .Net 2.0 / C#

I am looking to have a grid cell display a UltraDropDown control.  I want the drop down to display a sequence of years which can be selected or unselected (ideally using multi select).

The list starts off with every year within a range being selected.  The WinGrid cell display for this is 'startYear - endYear' where startYear and endYear are the bounds of the range - ie. "1960 - 2006".

The user wants to be able to click in the WinGrid on that cell and have all the years from 1960 to 2006 show up in a drop down box.  They can then unselect years.  When the user finishes unselecting the year(s), the UltraGrid cell will display with a yellow background to signify the range "1960 - 2006" is non-continious. The user also wants the dropdown to have a visual indication of which year(s) are un-selected.  I suspect the best way to do this is to have two columns to display in the dropdown, one with the year, the other with 'isSelected' indication.

I have been able to make the cell contain a DropDownList which unfortunately contains only the years.  (I do this by setting the column style to DropDownList - but this does not allow two columns to be displayed (ie a 'isSelected' status), and I have not been able to get a multi-select functionallity from the DropDownList.)

I am figuring the UltraDropDown can be used inside a WinGrid cell and can be used to display the year and its 'isSelected' status.

Can anyone show me a way set the column to display the UltraDropDown?  I have studied the 'Per Cell ValueList and Editors' sample provided by IG.

Follow-up questions:

1. Is it possible to make the cell's control a multi-select ultraDropDown?   - I do have a class possessing properties 'year' and 'isSelected'.

2. Any suggestions on how to retain the "1960 - 2006" display in the WinGrid cell, even when the user has selected / unselected years?

Gary

Parents Reply Children
No Data