TemplatePagerField.HandleEvent(CommandEventArgs) 方法

定義

處理 TemplatePagerField 物件中發生的事件並執行適當的動作。Handles events that occur in the TemplatePagerField object and performs the appropriate action.

public:
 override void HandleEvent(System::Web::UI::WebControls::CommandEventArgs ^ e);
public override void HandleEvent (System.Web.UI.WebControls.CommandEventArgs e);
override this.HandleEvent : System.Web.UI.WebControls.CommandEventArgs -> unit
Public Overrides Sub HandleEvent (e As CommandEventArgs)

參數

e
CommandEventArgs

事件資料。The event data.

備註

HandleEvent方法是 helper 方法。The HandleEvent method is a helper method. 當按一下控制項內的DataPager.OnBubbleEvent按鈕時, 方法會使用它來TemplatePagerField處理出現在物件中的事件。It is used by the DataPager.OnBubbleEvent method to handle events that occur in the TemplatePagerField object when a button inside the control is clicked.

方法會叫用DataPagerCommandEventArgs.NewStartRowIndex方法, 並檢查屬性。 OnPagerCommand HandleEventThe HandleEvent method invokes the OnPagerCommand method and examines the DataPagerCommandEventArgs.NewStartRowIndex property. 如果DataPagerCommandEventArgs.NewStartRowIndex已變更, 這個方法DataPager.SetPageProperties會叫用方法來更新DataPager控制項的頁面屬性。If DataPagerCommandEventArgs.NewStartRowIndex has changed, this method invokes the DataPager.SetPageProperties method to update the page properties of the DataPager control.

適用於

另請參閱