private void btnProdCodeSearch_Click(object sender, EventArgs e) { Cursor = System.Windows.Forms.Cursors.WaitCursor; using (Finder.ManuInventory frmInventory = new Finder.ManuInventory()) { if (frmInventory.ShowDialog() == DialogResult.OK) { if (frmInventory.sItemCode != "") { txtProdCode.Text = frmInventory.sItemCode.Trim(); txtDescription.Text = frmInventory.sItemDesc.Trim(); txtUnit.Text = frmInventory.sItemUnit.Trim(); ProductionLine plProductionLine = this; ProductionLine pllLastControl = this; txtQuantity.Focus(); } } } Cursor = System.Windows.Forms.Cursors.Default; }
private void cmdCodeSearch_Click(object sender, EventArgs e) { Cursor = System.Windows.Forms.Cursors.WaitCursor; using (Finder.ManuInventory frmInventory = new Finder.ManuInventory()) { if (frmInventory.ShowDialog() == DialogResult.OK) { if (frmInventory.sItemCode != "") { txtCode.Text = frmInventory.sItemCode.Trim(); StockIssueLine silStockIssue = this; StockIssueLine silLastControl = this; //bool bValid = Populate_Inventory_Fields(ref silStockIssue, true); txtCode.Focus(); txtCode.SelectionStart = 0; txtCode.SelectionLength = txtCode.Text.Length; } } } Cursor = System.Windows.Forms.Cursors.Default; }