private void btnPesquisar_Click(object sender, EventArgs e) { if (txbCDPrdt != null && !string.IsNullOrWhiteSpace(txbCDPrdt.Text)) { FormPrincipal.StaticGrid = ConManager.GetMovimentacaoCDProduto(FormPrincipal.StaticGrid, Int32.Parse(txbCDPrdt.Text)); this.Close(); } else { MessageBox.Show("Insira um valor"); } }