ArrayList arr1 = new ArrayList(); Item objItem = new Item(); objItem.Name="Vat"; objItem.Id="2"; arr1.Add(objItem); cmbLedgerType.DataSource = arr1; cmbLedgerType.DisplayMember = "Name"; cmbLedgerType.ValueMember = "Id"; ============================================================ Class Item { public string Name; public string Id; }
cmbLedgerType.DisplayMember = "Name"; cmbLedgerType.ValueMember = "Id"; cmbLedgerType.DataSource = arr1;
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)