Ejemplo n.º 1
0
        public ActionResult DeleteCategory()
        {
            string             categoryid = Request.QueryString["q"];
            ProductDataContext db         = new ProductDataContext();

            try
            {
                if (!string.IsNullOrEmpty(categoryid))
                {
                    db.SP_DeleteCategory(Convert.ToInt32(categoryid));
                }
            }
            catch (Exception ex)
            {
                throw;
            }

            return(RedirectToAction("Category"));
        }