P
Pingo
Hi!
How do I handle a Page event in my UserControl.
My .aspx page contain 5 different buttons and one of them is the SAVE button.
All buttons do PostBack to the page but only one should Save the data in the forms.
I want my UserControl to know when the SAVE button is clicked.
example:
//this code is what i would like in my UserControl
if (IsPostBack) {
if (???) { // Is Save Button = clicked
//Save some data in my UserControl
}
}
//this code is in the .aspx page
private void submitbtn_Click(object sender, System.EventArgs e) {
// do something here
}
private void InitializeComponent() {
this.submitbtn.Click += new System.EventHandler(this.submitbtn_Click);
}
Hope you understand my problem.
Kind Regards,
Pingo
How do I handle a Page event in my UserControl.
My .aspx page contain 5 different buttons and one of them is the SAVE button.
All buttons do PostBack to the page but only one should Save the data in the forms.
I want my UserControl to know when the SAVE button is clicked.
example:
//this code is what i would like in my UserControl
if (IsPostBack) {
if (???) { // Is Save Button = clicked
//Save some data in my UserControl
}
}
//this code is in the .aspx page
private void submitbtn_Click(object sender, System.EventArgs e) {
// do something here
}
private void InitializeComponent() {
this.submitbtn.Click += new System.EventHandler(this.submitbtn_Click);
}
Hope you understand my problem.
Kind Regards,
Pingo