Esempio n. 1
0
        public void Excluir(int intJogos)
        {
            try
            {
                objJogosBll = new Jogos();

                //objJogosBll.Excluir(intJogos);
                //ClientScript.RegisterStartupScript(Page.GetType(), "ExcluirOk", "alert('Excluiu')", true);
                if (objJogosBll.Excluir(intJogos))
                {
                    ClientScript.RegisterStartupScript(Page.GetType(), "ExcluirOk", "alert('Excluiu')", true);
                }
                else
                {
                    ClientScript.RegisterStartupScript(Page.GetType(), "ExcluirFalhou", "alert('NAO Excluiu')", true);
                }
            }
            catch (Exception ex)
            {
                ClientScript.RegisterStartupScript(Page.GetType(), "crash", "alert('ERRO!! NAO Excluiu')", true);
            }
        }