Example #1
0
        private void PopulaGrid_Funcionarios()
        {
            try
            {
                String queryBus_Func = "";

                ConexaoMYSQL StringConexao = new ConexaoMYSQL();


                StringConexao.StrConectaBancoMySql();

                SqlDS_BuscaFuncionario.ConnectionString = StringConexao.connectionString;
                queryBus_Func = "select func.idfuncionario, func.Nome, func.salario from tbfuncionario func;";
                SqlDS_BuscaFuncionario.SelectCommand = queryBus_Func;

                StringConexao.StrDesconectaMySql();
            }
            catch (Exception ex)
            {
                //throw;
            }
        }
        private void PopulaGrid_Vendas()
        {
            try
            {
                String queryBus_Func = "";

                ConexaoMYSQL StringConexao = new ConexaoMYSQL();


                StringConexao.StrConectaBancoMySql();

                SqlDS_BuscaVenda.ConnectionString = StringConexao.connectionString;
                queryBus_Func = "select idvenda, funcionario, valorCarro, comissao from tbvenda;";
                SqlDS_BuscaVenda.SelectCommand = queryBus_Func;

                StringConexao.StrDesconectaMySql();
            }
            catch (Exception ex)
            {
                //throw;
            }
        }