1.You need to define an event handler in user conrol as shown below.
public partial class UC_Pagination : System.Web.UI.UserControl
{
...
...
public event EventHandler PageIndexChanged;
...
...
...
}
2. You need to call the event explicitly in the user control's implementation of the event handler of button click as shown here
public partial class UC_Pagination : System.Web.UI.UserControl
{
...
...
protected void Button1_Click(object sender, EventArgs e)
{
...
...
PageIndexChanged(sender, e);
...
...
}
...
...
...
}
3. Implement the event handler bubbled up by user control in the parent page/control in its own way as usual (shown below).
public partial class Coaches : System.Web.UI.Page
{
...
...
protected void ucPaginationPageIndexChanged(object sender, EventArgs e)
{
...
...
...
}
...
...
}



4 comments:
Good. Nice one.
Blogs are so informative where we get lots of information on any topic. Nice job keep it up!!
_____________________________
Communication Dissertation
God never shuts one door but he opens another. ........................................
This kind of information is very limited on internet. Nice to find the post related to my searching criteria. Your updated and informative post will be appreciated by blog loving people.
Dissertation Format
Post a Comment