protected override void Delete()
        {
            ProductManager mgr =
              new ProductManager();

            // Create new entity
            Entity = new Product();

            // Get primary key from EventArgument
            Entity.ProductId =
              Convert.ToInt32(EventArgument);

            // Call data layer to delete record
            mgr.Delete(Entity);

            // Reload the Data
            Get();

            base.Delete();
        }
        protected override void Edit()
        {
            ProductManager mgr =
             new ProductManager();

            // Get Product Data
            Entity = mgr.Get(
              Convert.ToInt32(EventArgument));

            base.Edit();
        }
        protected override void Save()
        {
            ProductManager mgr =
              new ProductManager();

            if (Mode == "Add")
            {
                mgr.Insert(Entity);
            }
            else
            {
                mgr.Update(Entity);
            }

            // Set any validation errors
            ValidationErrors = mgr.ValidationErrors;

            // Set mode based on validation errors
            base.Save();
        }
        protected override void Get()
        {
            ProductManager mgr = new ProductManager();

            Products = mgr.GetProduct(SearchEntity);

            base.Get();
        }