1
Answer

Combobox Find Itmem using uniqueidentifier

Photo of Lee Thomas

Lee Thomas

14y
2.5k
1

I have a combobox databound to a table, Regions. The DataTextField is set to region name and the DataValueField is set to RegionID which is a unique identifier GUID.
Region.SelectedIndex = Region.FindItemIndexByText(rowView[
"RegionKey"].ToString());
Region.SelectedIndex = Region.FindItemIndexByValue(rowView["RegionKey"].ToString());
Neither of the above statements work with the GUID. How do you FindItemIndex with GUID`s
Regards, Lee

Answers (1)