Basically I am using valuelist to display names in place of ID's on a grid.
That works ok, however I am trying to figure out how to "shorten the list" as the items are used becase I need unique (names) on my grid.
I was hoping there is a way to flag items to not display, I can't delete them from the list because then it seems that when the grid displays it defaults to displaying the ID's because there is nothing in the list to correlate.
What is the best practice in this situation?
You need to set each cell its own list.
Set the column valuelist to the whole list. Handle BeforeCellActivate. Copy the items from the column valuelist to the cell valuelist except from the values in the same column in other rows.
I don't see that as being a "good" solution.
I have two lists, one complete list of names, the other names not used.
On dropdown, I want only to display names not used. While keeping the valuelist items data intact.
Currently what I have done is to change the appearance on the ones being used (palegreen) i.e.
It would be better if I could separate the dropdown list from the list in the grid. Or it would be better if the user tries to pick one colored "palegreen", it doesn't pick that item (because it was already used).
foreach (tblPriceSheet v1 in v2)
{
vPriceSheet.ValueListItems.Add(v1.GenPriceSheetID, v1.PriceSheetDesc + " " + v1.PriceSheetName);
if (myUsedValues.Contains(v1.GenPriceSheetID))
vPriceSheet.ValueListItems[vPriceSheet.ValueListItems.Count - 1].Appearance.BackColor = Color.PaleGreen;
}
foxjazz said: On dropdown, I want only to display names not used. While keeping the valuelist items data intact.
I think that's exactly what I suggested. You keep the original list in the column, but each cell gets his own list which contains the items that weren't selected in other rows.
You could also use UltraDropDown as your list and filter the list based on the values that exist in the other rows.