예제 #1
0
        public Boolean ValidaCPF(string strValida)
        {
            clsFuncionario    teste  = new clsFuncionario();
            clsFuncionarioBLL teste1 = new clsFuncionarioBLL();

            teste.CPF_Funcionario = strValida;

            DataTable dt = new DataTable();

            dt = teste1.SelecionaFuncionario(teste);

            try
            {
                if (dt.Rows.Count > 0)
                {
                    return(false);
                }
            }
            catch (Exception)
            {
                MessageBox.Show("Falha ao consultar CPF do Funcionario");
            }

            return(true);
        }
예제 #2
0
        public void preenchegrid()
        {
            clsFuncionario    teste  = new clsFuncionario();
            clsFuncionarioBLL teste1 = new clsFuncionarioBLL();

            teste1.SelecionaFuncionario(teste);
        }
예제 #3
0
        private void mtxtBuscaPorCPF_TextChanged(object sender, EventArgs e)
        {
            clsFuncionario    teste  = new clsFuncionario();
            clsFuncionarioBLL teste1 = new clsFuncionarioBLL();

            teste.CPF_Funcionario    = mtxtBuscaPorCPF.Text.ToString();
            dtgv_gravacao.DataSource = teste1.SelecionaFuncionario(teste);
        }
예제 #4
0
        private void Funcionario_Load(object sender, EventArgs e)
        {
            clsFuncionario    teste   = new clsFuncionario();
            clsFuncionarioBLL testte1 = new clsFuncionarioBLL();

            dtgv_gravacao.DataSource = testte1.SelecionaFuncionario(teste);

            btn_alterar.Enabled = false;
            btn_excluir.Enabled = false;
            valida_cargo        = false;
        }