Hi
I am workingon a .NET 2.0 project using Ultrawingrid. I am binding values to a column which has units at the end.
like (750ml, 50g, 500mg, 21IU).
I want to get only the actual value without the units. (like 750,50,500,21) when i read using cell.value.
How to have a different Display text and value for a column? In dropdown column we have option to add
value list and have a specif value for each display text.
Is it possible to store the actual values in a valuelist and get the values using cell.value for
normal cell type?
ThanksAshok
You can add a valuelist to any column.
column.ValueList = yourList
If you don't want it to look like a dropdown, change the column style to ColumnStyle.Edit
I'm not entirely sure what you are asking. Attaching a ValueList to the cell is not going to change the cell.Value, it will only change the display.
If you want the cell value to only have a numeric value, then you would have to do this on your data source. The grid can't give you a different value than what is in the cell.
Or you could simply get the value and strip out the letters to get a numeric value.