Hi All
In my web application user can select a value from a webcombo for an example user can select his favorite sport and save it. My problem is when user login and visit back to that page his favorite sport should be selected in the web combo . Please post the code for that. I'm using NetAdvantage for .NET 2008 Vol. 2 CLR 3.5.
Thanks in advance
Hi xakepu
Thank you very much for your help. Did few modifications to meet my need and It work.
Thanks again
Bugzila
Hi Bugzila,
I guess you can hook the DataBound event of the combo (at your Page-Load event) and then deside which record to be selected one.
You can use this sample code and modify it to suite your needs:
protected void Page_Load(object sender, EventArgs e) { WebCombo1.DataBound += new EventHandler(WebCombo1_DataBound); } void WebCombo1_DataBound(object sender, EventArgs e) { WebCombo1.SelectedRow = WebCombo1.Rows[2]; }