i would like my drop down list to retain the selected item when postback
cos everytime it postback, it goes back to the first item, any idea?
Printable View
i would like my drop down list to retain the selected item when postback
cos everytime it postback, it goes back to the first item, any idea?
What code do you have in your page_load event?
if Not page.ispostback then
ddl.datasource = ds.categories
.....
ddl.databind()
end if
Set its EnableViewState property to true.