本文整理汇总了C#中System.Web.UI.AsyncPostBackTrigger类的典型用法代码示例。如果您正苦于以下问题:C# AsyncPostBackTrigger类的具体用法?C# AsyncPostBackTrigger怎么用?C# AsyncPostBackTrigger使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
AsyncPostBackTrigger类属于System.Web.UI命名空间,在下文中一共展示了AsyncPostBackTrigger类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Page_Init
protected void Page_Init(object sender, EventArgs e)
{
#region 設定 Trigger
AsyncPostBackTrigger trigger1 = new AsyncPostBackTrigger();
trigger1.EventName = "Click";
trigger1.ControlID = this.but_Unusual_Report.UniqueID;
this.up_GridView.Triggers.Add(trigger1);
AsyncPostBackTrigger trigger2 = new AsyncPostBackTrigger();
trigger2.EventName = "Click";
trigger2.ControlID = this.ButtonQuery.UniqueID;
this.up_GridView.Triggers.Add(trigger2);
AsyncPostBackTrigger triggerA = new AsyncPostBackTrigger();
triggerA.EventName = "Click";
triggerA.ControlID = this.but_Unusual_Report.UniqueID;
this.up_ErrorMsg.Triggers.Add(triggerA);
AsyncPostBackTrigger triggerB = new AsyncPostBackTrigger();
triggerB.EventName = "Click";
triggerB.ControlID = this.ButtonQuery.UniqueID;
this.up_ErrorMsg.Triggers.Add(triggerB);
#endregion
}
示例2: Page_Load
protected void Page_Load(object sender, EventArgs e)
{
try
{
if (!IsPostBack)
{
hfSettingBase.Value = Request.RawUrl.Substring(Request.RawUrl.LastIndexOf('/') + 1) + "-PubNub-MV" + ((Table)Page.Master.FindControl("tblExpand")).Visible.ToString();
bool visible = true;
string dataVisible = SettingMgmt.getSetting(hfSettingBase.Value + "-Visible");
if (dataVisible != null)
{
bool.TryParse(dataVisible, out visible);
rowData.Visible = visible;
cbShow.Checked = visible;
}
AsyncPostBackTrigger trigger = new AsyncPostBackTrigger();
System.Web.UI.Timer tmrCheckChanges = (System.Web.UI.Timer)Page.Master.FindControl("tmrCheckChanges");
if (tmrCheckChanges != null && visible)
{
trigger.ControlID = tmrCheckChanges.ID;
UpdatePanelPubNub.Triggers.Add(trigger);
}
}
}
catch (Exception ex)
{
throw; //EventLog.WriteEntry("WinkAtHome.PubNubDisplay.Page_Load", ex.Message, EventLogEntryType.Error);
}
}
示例3: Page_Init
private void Page_Init(object sender, System.EventArgs e)
{
#region 設定 updatepanel1 trigger
AsyncPostBackTrigger trigger_up_Msg1 = new AsyncPostBackTrigger();
trigger_up_Msg1.EventName = "Click";
trigger_up_Msg1.ControlID = this.btnSet.UniqueID;
this.up_ErrorMsg.Triggers.Add(trigger_up_Msg1);
AsyncPostBackTrigger trigger_up_Msg2 = new AsyncPostBackTrigger();
trigger_up_Msg2.EventName = "Click";
trigger_up_Msg2.ControlID = this.btnUnSet.UniqueID;
this.up_ErrorMsg.Triggers.Add(trigger_up_Msg2);
AsyncPostBackTrigger trigger_up_Msg3 = new AsyncPostBackTrigger();
trigger_up_Msg3.EventName = "Click";
trigger_up_Msg3.ControlID = this.btnLock.UniqueID;
this.up_ErrorMsg.Triggers.Add(trigger_up_Msg3);
AsyncPostBackTrigger trigger2 = new AsyncPostBackTrigger();
trigger2.EventName = "Click";
trigger2.ControlID = this.ButtonQuery.UniqueID;
this.up_GridView.Triggers.Add(trigger2);
#endregion
}
示例4: Page_Init
protected void Page_Init(object sender, EventArgs e)
{
#region 設定 Trigger
#region 設定 up_Msg trigger
AsyncPostBackTrigger trigger_up_Msg1 = new AsyncPostBackTrigger();
trigger_up_Msg1.EventName = "Click";
trigger_up_Msg1.ControlID = this.but_Query.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg1);
AsyncPostBackTrigger trigger_up_Msg2 = new AsyncPostBackTrigger();
trigger_up_Msg2.EventName = "PageIndexChanging";
trigger_up_Msg2.ControlID = this.gv_Main_Query.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg2);
AsyncPostBackTrigger trigger_up_Msg3 = new AsyncPostBackTrigger();
trigger_up_Msg3.EventName = "Sorting";
trigger_up_Msg3.ControlID = this.gv_Main_Query.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg3);
AsyncPostBackTrigger trigger_up_Msg4 = new AsyncPostBackTrigger();
trigger_up_Msg4.EventName = "RowCommand";
trigger_up_Msg4.ControlID = this.gv_Main_Query.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg4);
AsyncPostBackTrigger trigger_up_Msg5 = new AsyncPostBackTrigger();
trigger_up_Msg5.EventName = "PageIndexChanging";
trigger_up_Msg5.ControlID = this.gv_Detl_Query.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg5);
AsyncPostBackTrigger trigger_up_Msg6 = new AsyncPostBackTrigger();
trigger_up_Msg6.EventName = "Sorting";
trigger_up_Msg6.ControlID = this.gv_Detl_Query.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg6);
#endregion
#region 設定 up_Main_Query trigger
AsyncPostBackTrigger trigger_up_Main_Query1 = new AsyncPostBackTrigger();
trigger_up_Main_Query1.EventName = "Click";
trigger_up_Main_Query1.ControlID = this.but_Query.UniqueID;
this.up_Main_Query.Triggers.Add(trigger_up_Main_Query1);
#endregion
#region 設定 up_Detl_Query trigger
AsyncPostBackTrigger trigger_up_Detl_Query1 = new AsyncPostBackTrigger();
trigger_up_Detl_Query1.EventName = "RowCommand";
trigger_up_Detl_Query1.ControlID = this.gv_Main_Query.UniqueID;
this.up_Detl_Query.Triggers.Add(trigger_up_Detl_Query1);
#endregion
#endregion
}
示例5: Page_Init
private void Page_Init(object sender, System.EventArgs e)
{
#region
WUI_GMToolbarV uc = (WUI_GMToolbarV)this.GMToolbar1;
// uc.Btn_New += new WUI_GMToolbarV.UCDelegate(this.UC_New);
uc.Btn_Find += new WUI_GMToolbarV.UCDelegate(this.UC_Find);
uc.Btn_FindExport += new WUI_GMToolbarV.UCDelegate(this.UC_Export);
#endregion
#region 設定 Trigger
AsyncPostBackTrigger trigger_up_Msg1 = new AsyncPostBackTrigger();
trigger_up_Msg1.EventName = "Click";
trigger_up_Msg1.ControlID = ButtonQuery_1.UniqueID;
UpdatePanel1.Triggers.Add(trigger_up_Msg1);
AsyncPostBackTrigger trigger_up_Msg2 = new AsyncPostBackTrigger();
trigger_up_Msg2.EventName = "Click";
trigger_up_Msg2.ControlID = ButtonQuery_2.UniqueID;
UpdatePanel1.Triggers.Add(trigger_up_Msg2);
AsyncPostBackTrigger trigger_up_Msg3 = new AsyncPostBackTrigger();
trigger_up_Msg3.EventName = "Click";
trigger_up_Msg3.ControlID = ButtonQuery_3.UniqueID;
UpdatePanel1.Triggers.Add(trigger_up_Msg3);
AsyncPostBackTrigger trigger_up_Msg4 = new AsyncPostBackTrigger();
trigger_up_Msg4.EventName = "Click";
trigger_up_Msg4.ControlID = ButtonQuery_4.UniqueID;
UpdatePanel1.Triggers.Add(trigger_up_Msg4);
#endregion
}
示例6: AppendTrigger
public static void AppendTrigger(this UpdatePanel up, string controlId, string eventName)
{
AsyncPostBackTrigger tg = new AsyncPostBackTrigger();
tg.ControlID = controlId;
tg.EventName = eventName;
up.Triggers.Add(tg);
}
示例7: Page_Init
/// <summary>
/// Page預設起始作業
/// </summary>
private void Page_Init(object sender, System.EventArgs e)
{
WUI_GMToolbarV uc = (WUI_GMToolbarV)this.GMToolbar1;
//uc.Btn_New += new WUI_GMToolbarV.UCDelegate(this.UC_New);
uc.Btn_Find += new WUI_GMToolbarV.UCDelegate(this.UC_Find);
//uc.Btn_FindExport += new WUI_GMToolbarV.UCDelegate(UC_Export);
uc.Btn_RecFirst += new WUI_GMToolbarV.UCDelegate(UC_RecFirst);
uc.Btn_RecLast += new WUI_GMToolbarV.UCDelegate(UC_RecLast);
uc.Btn_RecNext += new WUI_GMToolbarV.UCDelegate(UC_RecNext);
uc.Btn_RecPre += new WUI_GMToolbarV.UCDelegate(UC_RecPre);
#region ToolBar "第一筆"鈕
AsyncPostBackTrigger trigger_RecFirst1 = new AsyncPostBackTrigger();
trigger_RecFirst1.EventName = "Click";
trigger_RecFirst1.ControlID = ((ImageButton)GMToolbar1.Controls[0].Controls[25]).UniqueID;
this.PanelDetail.Triggers.Add(trigger_RecFirst1);
#endregion
#region ToolBar "最後一筆"鈕
AsyncPostBackTrigger trigger_RecLast1 = new AsyncPostBackTrigger();
trigger_RecLast1.EventName = "Click";
trigger_RecLast1.ControlID = ((ImageButton)GMToolbar1.Controls[0].Controls[31]).UniqueID;
this.PanelDetail.Triggers.Add(trigger_RecLast1);
#endregion
#region ToolBar "下一筆"鈕
AsyncPostBackTrigger trigger_RecNext1 = new AsyncPostBackTrigger();
trigger_RecNext1.EventName = "Click";
trigger_RecNext1.ControlID = ((ImageButton)GMToolbar1.Controls[0].Controls[29]).UniqueID;
this.PanelDetail.Triggers.Add(trigger_RecNext1);
#endregion
#region ToolBar "上一筆"鈕
AsyncPostBackTrigger trigger_RecPre1 = new AsyncPostBackTrigger();
trigger_RecPre1.EventName = "Click";
trigger_RecPre1.ControlID = ((ImageButton)GMToolbar1.Controls[0].Controls[27]).UniqueID;
this.PanelDetail.Triggers.Add(trigger_RecPre1);
#endregion
}
示例8: Page_Init
private void Page_Init(object sender, System.EventArgs e)
{
#region
WUI_GMToolbarV uc = (WUI_GMToolbarV)this.GMToolbar1;
uc.Btn_RecFirst += new WUI_GMToolbarV.UCDelegate(this.UC_RecFirst);
uc.Btn_RecLast += new WUI_GMToolbarV.UCDelegate(this.UC_RecLast);
uc.Btn_RecNext += new WUI_GMToolbarV.UCDelegate(this.UC_RecNext);
uc.Btn_RecPre += new WUI_GMToolbarV.UCDelegate(this.UC_RecPre);
uc.Btn_New += new WUI_GMToolbarV.UCDelegate(this.UC_New);
uc.Btn_Edit += new WUI_GMToolbarV.UCDelegate(this.UC_Edit);
uc.Btn_Find += new WUI_GMToolbarV.UCDelegate(this.UC_Find);
uc.Btn_Delete += new WUI_GMToolbarV.UCDelegate(this.UC_Delete);
uc.Btn_Save += new WUI_GMToolbarV.UCDelegate(this.UC_Save);
uc.Btn_Copy += new WUI_GMToolbarV.UCDelegate(this.UC_Copy);
AsyncPostBackTrigger trigger_up_Msg1 = new AsyncPostBackTrigger();
trigger_up_Msg1.EventName = "Click";
trigger_up_Msg1.ControlID = this.btnImport.UniqueID;
this.UpdatePanel1.Triggers.Add(trigger_up_Msg1);
AsyncPostBackTrigger trigger_up_Msg2 = new AsyncPostBackTrigger();
trigger_up_Msg2.EventName = "Click";
trigger_up_Msg2.ControlID = this.btnAdd.UniqueID;
this.UpdatePanel1.Triggers.Add(trigger_up_Msg2);
#endregion
}//Page_Init
示例9: Page_Init
private void Page_Init(object sender, System.EventArgs e)
{
#region 設定 Trigger
AsyncPostBackTrigger trigger1 = new AsyncPostBackTrigger();
trigger1.EventName = "Click";
trigger1.ControlID = this.btnSave.UniqueID;
this.UpdatePanel2.Triggers.Add(trigger1);
#endregion
}
示例10: Page_Init
protected void Page_Init(object sender, EventArgs e)
{
#region 設定 Trigger
#region 設定 up_Msg
AsyncPostBackTrigger trigger_up_Msg1 = new AsyncPostBackTrigger();
trigger_up_Msg1.EventName = "Click";
trigger_up_Msg1.ControlID = this.btn_Rollback.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg1);
#endregion
#endregion
}
示例11: Page_Init
protected void Page_Init(object sender, EventArgs e)
{
#region 設定 Trigger
#region 設定 up_QueryResult
AsyncPostBackTrigger trigger_up_QueryResult1 = new AsyncPostBackTrigger();
trigger_up_QueryResult1.EventName = "Click";
trigger_up_QueryResult1.ControlID = this.but_Query.UniqueID;
this.up_QueryResult.Triggers.Add(trigger_up_QueryResult1);
#endregion
#endregion
}
示例12: Page_Init
private void Page_Init(object sender, System.EventArgs e)
{
#region
AsyncPostBackTrigger trigger_up_Msg1 = new AsyncPostBackTrigger();
trigger_up_Msg1.EventName = "Click";
trigger_up_Msg1.ControlID = this.btnQuery.UniqueID;
this.UpdatePanel1.Triggers.Add(trigger_up_Msg1);
AsyncPostBackTrigger trigger_up_Msg2 = new AsyncPostBackTrigger();
trigger_up_Msg2.EventName = "Click";
trigger_up_Msg2.ControlID = this.btnQuery.UniqueID;
this.up_Msg.Triggers.Add(trigger_up_Msg2);
#endregion
}
示例13: Page_Init
private void Page_Init(object sender, System.EventArgs e)
{
#region 設定 Trigger
AsyncPostBackTrigger trigger1 = new AsyncPostBackTrigger();
trigger1.EventName = "Click";
trigger1.ControlID = this.ButtonQuery.UniqueID;
this.UpdatePanel1.Triggers.Add(trigger1);
AsyncPostBackTrigger trigger2 = new AsyncPostBackTrigger();
trigger2.EventName = "Click";
trigger2.ControlID = this.ButtonNew.UniqueID;
this.UpdatePanel1.Triggers.Add(trigger2);
#endregion
}
示例14: GV_RowDataBound
protected void GV_RowDataBound(object sender, GridViewRowEventArgs e)
{
if (e.Row.RowType == DataControlRowType.DataRow)
{
var lb_Select = (LinkButton)e.Row.FindControl("lb_Select");
var lb_Delete = (LinkButton)e.Row.FindControl("lb_Delete");
lb_Select.OnClientClick = Page.ClientScript.GetPostBackEventReference(GV, "Select$" + e.Row.RowIndex) + ";return false;";
lb_Delete.OnClientClick = "if (confirm('Are you sure you want to delete this product?')) {" + Page.ClientScript.GetPostBackEventReference(GV, "Delete$" + e.Row.RowIndex) + ";}return false;";
var Trigger = new AsyncPostBackTrigger();
Trigger.ControlID = GV.ID;
Trigger.EventName = "";
UP.Triggers.Add(Trigger);
}
}
示例15: CreateChildControls
protected override void CreateChildControls()
{
base.CreateChildControls();
// Update パネルを使うときは、この関数を "おまじないで" 呼び出しましょう !
EnsurePanelFix();
// ラベルを追加
label1.Text = "商品(キーワードを入力し選択) : ";
this.Controls.Add(label1);
// テキストボックスを追加
textbox1.ID = "SearchStringTextBox";
textbox1.Width = 300;
textbox1.AutoPostBack = true;
textbox1.TextChanged += new EventHandler(autoCompleteTextbox_TextChanged);
this.Controls.Add(textbox1);
// 改行を追加
lCrLf.Text = "<br />";
this.Controls.Add(lCrLf);
// UpdatePanel のトリガーを設定 (テキストボックスが更新されたら Update !)
updPanel1.ChildrenAsTriggers = false;
updPanel1.UpdateMode = UpdatePanelUpdateMode.Conditional;
AsyncPostBackTrigger updTrigger1 = new AsyncPostBackTrigger();
updTrigger1.ControlID = "SearchStringTextBox";
updTrigger1.EventName = "TextChanged";
updPanel1.Triggers.Add(updTrigger1);
// UpdatePanel にコントロールを追加
updPanel1.ContentTemplateContainer.Controls.Add(photoImage);
// UpdatePanel を追加
this.Controls.Add(updPanel1);
// さらに、テキストボックスに AutoComplete Extender (Ajax Contorol Toolkit の部品の 1 つ) を設定
autoCompleteCtrl.MinimumPrefixLength = 1;
/*****
(ドメインをまたがったデータソースへのアクセスは、
ブラウザの設定によってエラーとなるため、相対パスで記載)
*****/
autoCompleteCtrl.ServicePath = "/_vti_bin/KakakuSearch.asmx";
autoCompleteCtrl.ServiceMethod = "GetSelectableNames";
autoCompleteCtrl.TargetControlID = "SearchStringTextBox";
this.Controls.Add(autoCompleteCtrl);
}