I need to check if an item is in my datasource on post back. I am using C# with asp.net. What I have is a cascading dropdown, where the first dropdown's selected item(projects) determines the second dropdown(users). I would like to store the user and keep it "selected" if they exist in another project.
My psuedo code looks like this, but I'm not sure about syntax:
string selectedusername = dropdown2.selecteditem;
if (selectedusername is in datasource items)
dropdown1.selecteditem = selectedusername
thanks in advance