Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Empty combo
Message
General information
Forum:
ASP.NET
Category:
Other
Title:
Miscellaneous
Thread ID:
00884521
Message ID:
00885748
Views:
14
Bob,

SelectedIndex works for me. I set it to the index (zero-based) of the combo-box item I want to have selected.

>>Bob,
>>
>>Setting -1 works for WinForms.
>
>What works in web forms? Say on a post back I want to set the selected item back to the empty record (index 0)? SelectedIndex doesn't seem to work at all on the web forms.
>
>I guess I can do the same that I do to find a value...
>
>ddl.Items.FindByValue("").Selected = true;
>
>Thanks,
>BOb
-----------------------------------------

Cathi Gero, CPA
Prenia Software & Consulting Services
Microsoft C# / .NET MVP
Mere Mortals for .NET MVP
cgero@prenia.com
www.prenia.com
Weblog: blogs.prenia.com/cathi
Previous
Reply
Map
View

Click here to load this message in the networking platform