[thelist] (asp.net) Custom Events on user controls?

Tab Alleman talleman at Lumpsum.com
Fri Feb 17 17:11:40 CST 2006

I do want to specify which event triggers the postback... I suppose I could check the request.params.  A co-worker just suggested putting a method in my control, and calling that method in the Submit_Click event on the containing page.  It sounds pretty reasonable to me, but maybe there's a gotcha waiting around that corner...?

> -----Original Message-----
> From: thelist-bounces at lists.evolt.org
> [mailto:thelist-bounces at lists.evolt.org]On Behalf Of Peter Brunone
> (EasyListBox.com)
> Sent: Friday, February 17, 2006 5:07 PM
> To: thelist at lists.evolt.org; thelist at lists.evolt.org
> Subject: Re: [thelist] (asp.net) Custom Events on user controls?
> Couldn't you just check Page.IsPostBack from the user 
> control?  Or are you looking for a specific event that 
> triggered postback?
> Another approach would be to create public properties on the 
> UC that map to the form fields in question; you could then 
> read these properties from the containing page. 
> HTH,
> Peter
>  From: "Tab Alleman" talleman at Lumpsum.com
> I've created a user control that has some form fields on it, 
> however, it doesn't have a submit button. The submit button 
> is on the outer page that contains the user control.
> Is there a standard way to have the outer page fire a 
> subroutine in the user control so that when the submit button 
> is clicked, the user control is aware of it and saves the 
> data in its form fields?
> -- 
> * * Please support the community that supports you.  * *
> http://evolt.org/help_support_evolt/
> For unsubscribe and other options, including the Tip Harvester 
> and archives of thelist go to: http://lists.evolt.org 
> Workers of the Web, evolt ! 

More information about the thelist mailing list