Lets say I have a row that can store GUID.
But I don't want my grid to show the guid but something else .... how can it be done ?
My problem is that i have this column that is called Terminated By
A task can be terminated by an employee OR a crew for example. which are both GUID.
So how can I achieve to show the employee name or a crew name in that column ..... instead of the GUID. I also have another column that enable to specify by what type of operator has terminated the task, an employee or a crew, and then when going to the Terminated By column, it opens a combobox of a list of values of employee or crew depending on your choice.
Is this possible?
Yes, a ValueList allows you to specify a DataValue and a DisplayText for each item. This is expressly for the purpose of storing a value and displaying more user-friendly text to the user.
But when I set the value into the cell with a GUID, and populate the valuelist, will the grid show the display name and not the value(guid) automatically?
There are many ways to do that.
Can you make a list of your guids and display value for each of them? If that's the case, I think using a value list is the simplest approach.
var list = grid.DisplayLayout.ValueLists.Add();
list.ValueListItems.Add(value, name);
column.ValueList = list
help?