Hi. I need to set value to cell that not in value list, it sets but it shows in cell myValue.ToString() string , is it possible to handle what cell will show if value not in value list?
so, my goal is to show value in cell but don't allow user to chose it from dropdown. Please advice.
Hi,
Please, check the attached sample where I have set the Style of the grid's column to DropDownList. There is no way now to type or select the hidden row with Activation set to Disabled. One more point - setting the DropDownStyle to UltraCombo has no effect here. UltraCombo is actually provides its editor to the grid. What you do next is setting all the necessary properties to the grid's column / cell.
Thank you for using Infragistics Controls.
As far as I can tell, setting the Activation property on the UltraCombo's row, hidden or not, does not prevent a hidden value from being typed in. This is with an UltraCombo set to the DropDownList style with LimitToList set True. You can always check in BeforeRowUpdate, but Activation has no effect in this instance.
Hello Kyril,
I am just checking about the progress of this issue. Let me know if you need my further assistance on it.
Thank you for using Infragistics Components.
Thank you for your feedback.
I have checked your example. In order to add values to the value list and to be able to hide some of the values you may use UltraDropDown instead of ValueList. UltraDropDown is essentially a dropdown UltraWinGrid (although it is limited to a single band). It will allow to hide rows and columns. In order to make it work in your scenario you will need to bind the UltraDropDown to your myValues_ List. Then you will need to add two unbound columns – first one for DisplayMember, it will display the necessary strings and second one for ValueMember it will hold the MyClass object. Finally by iterating through all the rows in UltraDropDown you may hide all the rows with obsolete values. Please note in order to stop users to select such rows by typing the row value you will need to set Activation property of obsolete rows to Disabled.
Please find attached your revised sample solution and let me know if this is what you are looking for or if I am missing something.
Waiting for your feedback.
1. I do not have access to display value inside class.
2. MyClass
3. i create valuelist :
var vl= new ValueList();
vl.ValueListItems.Add(new MyClass{Value = value1}, "MyClassValue1");
vl.ValueListItems.Add(new MyClass{Value = value2}, "MyClassValue2");
vl.ValueListItems.Add(new MyClass{Value = value3}, "MyClassValue3");
grid_.DisplayLayout.Bands[0].Columns[columnName_].ValueList = vl;
4. Type of value is MyClass. for example i set value new MyClass{Value = value4};
I want to help with showing special text for value that should be displayed in cell but should be not selectable from dropdown.
In my example i need to show all values in cell but user should can ability to select values that not Obsolete. Is there way to set cell text or something else? Or add value to value list but do not show it in dropdown ? Or maybe is there a way to filter values that shown in dropdown?
Sample is atached