private void TelaPrincipal_Load(object sender, EventArgs e) { btnEntrada.Focus(); while (usr == null) { this.Hide(); Login tela = new Login(this); tela.ShowDialog(); } if (usr.Idfuncionario == 0) { Application.Exit(); } else { string[] nomeSplit = usr.Nome.Split(' '); lblUser.Text = nomeSplit[0]; this.Show(); } while (est == null && usr.Idfuncionario != 0) { IUEstabelecimento tela = new IUEstabelecimento(0, this); tela.ShowDialog(); BuscaEstabelecimento(); } while (config == null && usr.Idfuncionario != 0) { IUConfigMovimento tela = new IUConfigMovimento(est); tela.ShowDialog(); BuscaConfiguracao(); } CarregaGrid(); }
private void configuraçãoToolStripMenuItem_Click(object sender, EventArgs e) { IUConfigMovimento tela = new IUConfigMovimento(est); tela.ShowDialog(); BuscaConfiguracao(); }