I'm able to bind the WebCombo control to a datasource so it shows the list of values in the dropdown, but I can't figure out how to bind it to another datasource that will have the selected value. In the MS DropDownList, there's a SelectedValue property that can be bound, what's the equivalent for the WebCombo? I've tried using DisplayValue but get an error that Bind/Eval "can only be used in the context of a databound control".
Nathan
Nathan,
You can use something like this:
this.webCombo.Rows.FromKey("1").Selected = true; //if you want to select the row with Id=1
In the InitializeRow event you must set the key:protected void webCombo_InitializeRow(object sender, Infragistics.WebUI.UltraWebGrid.RowEventArgs e){ e.Row.Key = e.Row.Cells.FromKey("Id").Text;}
I hope it help.
Johni Ecco
Thanks for your reply, however is there the possibility to do this in the aspx page? and not directly in the C#