Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
35
DropDownProvider's DataSource
posted

I'm trying to edit a WebDataGrid's column with a DropDownProvider. I need to set the provider's editor control data source programmatically with a DataTable, but I can't get it work... any idea? I tried using an external WebDropDown, but I can't bind it to the DropDownProvider.

Thanks in advance! 

Parents
No Data
Reply
  • 375
    posted

    DropDownProvider ddp = (DropDownProvider) yourWebDataGrid.EditorProviders["ddp"];

    ddp.EditorControl.DataSource = <your datatable>                ddp.EditorControl.TextField = "Desc";

    ddp.EditorControl.ValueField = "ID";

    ddp.EditorControl.ValueDisplayType = Infragistics.Web.UI.ListControls.DropDownValueDisplayType.Simple;

Children