private void btnFind_Click(object sender, EventArgs e) { var oForm = new ChooseFromListForm((Array)ddlWarehouse.DataSource, "Code", "Name"); if (oForm.ShowDialog() == DialogResult.OK) { this.ddlWarehouse.SelectedValue = oForm.SelectedValue; } }
private void btnResumeBill_Click(object sender, EventArgs e) { var bills = ServiceHelper.MobileServices.GetHandHeldCounterMainHoldBillByUser(GlobalContext.BranchCode, GlobalContext.UserCode); var oForm = new ChooseFromListForm(bills, "Iblnr", "Docno"); if (oForm.ShowDialog() == DialogResult.OK) { ddlCounterBill.Text = oForm.SelectedValue; var counterHolds = ServiceHelper.MobileServices.GetHandHeldCounterMainHoldByDocumentNo(GlobalContext.BranchCode, oForm.SelectedText); bindingSource.DataSource = counterHolds; bindingSource.ResetBindings(false); ddlCounterBill.Enabled = false; btnSearch.Enabled = false; } }