public static void bindData(ListBox o, ListItemDataProvider provider) { o.DataSource = null; o.Items.Clear(); o.DisplayMember = UIDataFactory.VALUE; o.ValueMember = UIDataFactory.ID; o.DataSource = provider.getData(); }
public static void autoComplete(TextBox txt, ListItemDataProvider provider) { ListBox lb = null; autoCompleteListMap.TryGetValue(txt.Name,out lb); if (lb == null) { lb = registerAutoComplete(txt); } bindData(lb, provider); }