Hello,
Please can someone help!
I have a textbox and a dropdownlist. The text in the textbox also features as an item in my dropdownlist.
What i want to achieve is when i click a button, the dropdownlist loads with data but rather than dispay the first item in the dropdownlist at index 0, i wish for it to display the item that is equal to what is shown in the textbox.
I have tried the following:
ddlVendors.SelectedItem.Value = txtVend.Text
but this just displays the first item in the ddl and not the item in the textbox. I have also had a play around with selected index and selected value but no luck.
Any ideas anyone??
Please can someone help!
I have a textbox and a dropdownlist. The text in the textbox also features as an item in my dropdownlist.
What i want to achieve is when i click a button, the dropdownlist loads with data but rather than dispay the first item in the dropdownlist at index 0, i wish for it to display the item that is equal to what is shown in the textbox.
I have tried the following:
ddlVendors.SelectedItem.Value = txtVend.Text
but this just displays the first item in the ddl and not the item in the textbox. I have also had a play around with selected index and selected value but no luck.
Any ideas anyone??