Starbuck

Starbuck

  • NA
  • 3
  • 1.8k

User control executing method in main page

May 28 2006 11:48 PM

I have a UC that gathers data. When the user is ready to process the data they click a Submit in the UC. That should send the data to the parent page. I'm getting confused about exactly what goes in the UC, what goes in the parent, and how to hook them up for the data exchange.

It seems when the parent does a Page_Load or Page_LoadComplete that I can set a delegate in the UC instance, but after everything is loaded the delegate in the UC is null. It's like the parent is working with a different instance at load time than what exists at runtime - or maybe.  I have no problem working with delegates in Windows Forms so I'm guessing I'm missing something that's ASP.NET specific.

I know this is kinda vague, but can someone point me to a page with a simple example of the proper way to do this? Or maybe post some real basic guidelines for what needs to be done and when in each piece?  C# would be preferred, VB is OK if required.  Code specific to .NET 2.0 is also fine.

Thanks!!


Answers (1)