當前位置: 首頁>>代碼示例>>C#>>正文


C# WebControls.FormViewDeletedEventArgs類代碼示例

本文整理匯總了C#中System.Web.UI.WebControls.FormViewDeletedEventArgs的典型用法代碼示例。如果您正苦於以下問題:C# FormViewDeletedEventArgs類的具體用法?C# FormViewDeletedEventArgs怎麽用?C# FormViewDeletedEventArgs使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


FormViewDeletedEventArgs類屬於System.Web.UI.WebControls命名空間,在下文中一共展示了FormViewDeletedEventArgs類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: FormView1_ItemDeleted

 protected void FormView1_ItemDeleted(object sender, FormViewDeletedEventArgs e)
 {
     if (e.Exception == null || e.ExceptionHandled)
     {
         this.Response.Redirect(this.Table.ListActionPath);
     }
 }
開發者ID:Jarolim,項目名稱:AllMyHomeworkForTelerikAcademy,代碼行數:7,代碼來源:Details.aspx.cs

示例2: FormView1_ItemDeleted

 //-------------------------------------------------------------------------------------------
 protected void FormView1_ItemDeleted(object sender, FormViewDeletedEventArgs e)
 {
     //if (e.Exception == null || e.ExceptionHandled)
        //{
        //     Response.Redirect(table.ListActionPath);
        //}
 }
開發者ID:weavver,項目名稱:weavver,代碼行數:8,代碼來源:Page.aspx.cs

示例3: FormView1_ItemDeleted

        protected void FormView1_ItemDeleted(object sender, FormViewDeletedEventArgs e)
        {
            GridView1.DataBind();

            btneditar.Visible = false;
            btneliminar.Visible = false;
        }
開發者ID:Phate339,項目名稱:eng.soft.2,代碼行數:7,代碼來源:Gerir.aspx.cs

示例4: fvPersonDetails_ItemDeleted

        /// <summary>
        /// 刪除成功後 , 重新綁定數據.
        /// </summary>
        protected void fvPersonDetails_ItemDeleted(object sender, FormViewDeletedEventArgs e)
        {
            gvPersonOverView.DataBind();

            // 如果還有記錄
            if (gvPersonOverView.Rows.Count > 0)
            {
                // 取出被刪除記錄的行索引
                int delindex = (int)ViewState["delindex"];

                // 如果第一條記錄被刪除,移動到下一條記錄.
                if (delindex == 0)
                {
                    gvPersonOverView.SelectedIndex = 0;
                }

                // 如果是最後一條記錄被刪除, 移動到前一條記錄.
                else if (delindex == gvPersonOverView.Rows.Count)
                {
                    gvPersonOverView.SelectedIndex = gvPersonOverView.Rows.Count - 1;
                }

                // 否則, 刪除後移動到下一條記錄.
                else
                {
                    gvPersonOverView.SelectedIndex = delindex;
                }

            }

            // 如果沒有記錄, 變更為插入模式以插入數據.
            else
            {
                fvPersonDetails.ChangeMode(FormViewMode.Insert);
                fvPersonDetails.DefaultMode = FormViewMode.Insert;
            }
        }
開發者ID:zealoussnow,項目名稱:OneCode,代碼行數:40,代碼來源:Default.aspx.cs

示例5: HandleDeleteCallback

        private bool HandleDeleteCallback(int affectedRows, Exception ex) {
            int pageIndex = PageIndex;
            FormViewDeletedEventArgs fea = new FormViewDeletedEventArgs(affectedRows, ex);
            fea.SetKeys(_deleteKeys);
            fea.SetValues(_deleteValues);

            OnItemDeleted(fea);

            _deleteKeys = null;
            _deleteValues = null;

            if (ex != null && !fea.ExceptionHandled) {
                // If there is no validator in the validation group that could make sense
                // of the error, return false to proceed with standard exception handling.
                // But if there is one, we want to let it display its error instead of throwing.
                if (PageIsValidAfterModelException()) {
                    return false;
                }
            }

            if (pageIndex == _pageCount - 1) {
                HandlePage(pageIndex - 1);
            }

            RequiresDataBinding = true;
            return true;
        }
開發者ID:iskiselev,項目名稱:JSIL.NetFramework,代碼行數:27,代碼來源:FormView.cs

示例6: d_ItemDeleted

		static void d_ItemDeleted (object sender, FormViewDeletedEventArgs e)
		{
			if (WebTest.CurrentTest.UserData == null) {
				ArrayList list = new ArrayList ();
				list.Add ("ItemDeleted");
				WebTest.CurrentTest.UserData = list;
			}
			else {
				ArrayList list = WebTest.CurrentTest.UserData as ArrayList;
				if (list == null)
					throw new NullReferenceException ();
				list.Add ("ItemDeleted");
				WebTest.CurrentTest.UserData = list;
			}
		}
開發者ID:JokerMisfits,項目名稱:linux-packaging-mono,代碼行數:15,代碼來源:FormViewTest.cs

示例7: attractionsForm_ItemDeleted

 protected void attractionsForm_ItemDeleted(object sender, FormViewDeletedEventArgs e)
 {
       Response.RedirectToRoute("TouristAttraction");
     
 }
開發者ID:rustd,項目名稱:ASP.NET-MVC-and-DbGeography,代碼行數:5,代碼來源:Delete.aspx.cs

示例8: FormViewArticolo_ItemDeleted

 protected void FormViewArticolo_ItemDeleted(object sender, FormViewDeletedEventArgs e)
 {
     Response.Redirect(ViewState["PreviousPage"].ToString());//Redirect to 
 }
開發者ID:PaoloMisson,項目名稱:GATEvolution,代碼行數:4,代碼來源:ArticoliModifica.aspx.cs

示例9: FormView1_ItemDeleted

 //-------------------------------------------------------------------------------------------
 protected void FormView1_ItemDeleted(object sender, FormViewDeletedEventArgs e)
 {
     if (Page.MasterPageFile.Contains("Blank.master"))
        {
             ScriptManager.RegisterStartupScript(Page, this.GetType(), "closeIFrame", "<script type='text/javascript'>parent.closeIFrame('" + Request["WindowId"] + "', '" + Request["ParentId"] + "');</script>", false);
        }
        else
        {
             if (e.Exception == null || e.ExceptionHandled)
             {
                  Response.Redirect(RedirectURL);
             }
        }
 }
開發者ID:weavver,項目名稱:weavver,代碼行數:15,代碼來源:Details.aspx.cs

示例10: fvProcMaterialBalanceAdd_ItemDeleted

 protected void fvProcMaterialBalanceAdd_ItemDeleted(object sender, FormViewDeletedEventArgs e)
 {
     //當前刪除的id號
     var id = Int64.Parse(e.Keys[0].ToString());
     //執行跳轉
     JumpToUrlById(id);
 }
開發者ID:yangdan8,項目名稱:ydERPGJ,代碼行數:7,代碼來源:ProcMaterialBalanceAdd.aspx.cs

示例11: OnItemDeleted

 protected override void OnItemDeleted(FormViewDeletedEventArgs e)
 {
     base.OnItemDeleted(e);
     WebNavigator nav = this.GetBindingNavigator();
     if (nav != null)
     {
         WebDataSource ds = (WebDataSource)this.GetObjByID(this.DataSourceID);
         if (ds.AutoApply)
         {
             nav.SetState(WebNavigator.NavigatorState.ApplySucess);
             nav.SetNavState("Browsed");
         }
         else
         {
             nav.SetState(WebNavigator.NavigatorState.Changed);
             nav.SetNavState("Changing");
         }
     }
 }
開發者ID:san90279,項目名稱:UK_OAS,代碼行數:19,代碼來源:WebFormView.cs

示例12: OnItemDeleted

 protected virtual new void OnItemDeleted(FormViewDeletedEventArgs e)
 {
 }
開發者ID:asvishnyakov,項目名稱:CodeContracts,代碼行數:3,代碼來源:System.Web.UI.WebControls.FormView.cs

示例13: OnItemDeleted

 /// <devdoc>
 /// <para>Raises the <see langword='ItemDeleted '/>event.</para>
 /// </devdoc>
 protected virtual void OnItemDeleted(FormViewDeletedEventArgs e) {
     FormViewDeletedEventHandler handler = (FormViewDeletedEventHandler)Events[EventItemDeleted];
     if (handler != null) handler(this, e);
 }
開發者ID:iskiselev,項目名稱:JSIL.NetFramework,代碼行數:7,代碼來源:FormView.cs

示例14: FormView1_ItemDeleted

 protected void FormView1_ItemDeleted(object sender, FormViewDeletedEventArgs e)
 {
     Response.Redirect("~/Qualita/NonConformitaList.aspx");
 }
開發者ID:PaoloMisson,項目名稱:GATEvolution,代碼行數:4,代碼來源:NCModifica.ascx.cs

示例15: DeleteItem

		public virtual void DeleteItem ()
		{
			currentEditRowKeys = DataKey.Values;
			currentEditNewValues = GetRowValues (true);
			
			FormViewDeleteEventArgs args = new FormViewDeleteEventArgs (PageIndex, currentEditRowKeys, currentEditNewValues);
			OnItemDeleting (args);

			if (args.Cancel || !IsBoundUsingDataSourceID)
				return;

			if (PageIndex > 0 && PageIndex == PageCount - 1)
				PageIndex--;
				
			RequireBinding ();
				
			DataSourceView view = GetData ();
			if (view != null)
				view.Delete (currentEditRowKeys, currentEditNewValues, new DataSourceViewOperationCallback (DeleteCallback));
			else {
				FormViewDeletedEventArgs dargs = new FormViewDeletedEventArgs (0, null, currentEditRowKeys, currentEditNewValues);
				OnItemDeleted (dargs);
			}
		}	
開發者ID:Profit0004,項目名稱:mono,代碼行數:24,代碼來源:FormView.cs


注:本文中的System.Web.UI.WebControls.FormViewDeletedEventArgs類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。