I have a User Control with with some search functionality, then I also have a control that contains a grid. In the control that has the grid I have all the functionality to retrieve some items I need to populate a report from the search control.
My question is, and I have read about this but not completely sure how to make it work, I read i need to register a event handler in control A that calls the function in control B. How does that work?
Say in control B there is a function that I need to call GetAllItemsByRegistrantID(int id). How can I make a call to this function from control A?
I would really appreciate any help or guidance on this.
Regards
Here is an example if you had to do it using events.
On your first user control (the search control) define a custom event.
On your user control with the grid, define a handler.
On the page where they both live, wire them together.