protected void ShowBook(EntClsBook book)
        {
            textTitle.Text       = book.Name;
            textIsbn.Text        = book.Isbn;
            textDatePublish.Text = book.DatePublish;
            textStock.Text       = Convert.ToString(book.Stock);
            textState.Text       = book.StateB;
            EntClsCategory ent_categ = bsn_cate.listCategoryForid(book.IdCateg);

            textCategory.Text = ent_categ.Name;
            EntClsEditorial ent_edit = bsn_edit.checkEditorialForId(book.IdEdit);

            textEdit.Text = ent_edit.Name;
            EntClsWrite  ent_write  = bsn_write.listWriteForCode(book.Code);
            EntClsAuthor ent_author = bsn_auth.checkAuthorForId(ent_write.IdAuthor);

            textAuthor.Text = ent_author.Name + ' ' + ent_author.LastName;
        }
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["admin"] == null)
            {
                Response.Redirect("Login.aspx");
            }
            if (Session["author"] == null)
            {
                Response.Redirect("Autor.aspx");
            }

            if (Session["book"] != null)
            {
                ent_book              = bsn_book.SearchEditorialOfBook(Session["book"].ToString());
                obj_edit              = bsn_edit.checkEditorialForId(ent_book.IdEdit);
                textName.Text         = obj_edit.Name;
                textCity.Text         = obj_edit.City;
                textCountry.Text      = obj_edit.Country;
                btnNextBook.Visible   = false;
                btnUpdateCont.Visible = true;
                btnUpdateCont.Enabled = true;
                code            = Session["book"].ToString();
                insert          = 3;
                Session["book"] = null;
            }
            else
            {
                if (Session["regis"] != null)
                {
                    btnNextBook.Visible   = true;
                    btnUpdateCont.Visible = false;
                }
            }

            if (!IsPostBack)
            {
                rblEditorial.AutoPostBack = true;
            }
        }