Access the answers to your technology questions today.
Subscribe Now
30-day free trial. Register in 60 seconds.
What Makes Experts Exchange Unique?
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.
Try it out and discover for yourself.
Subscribe Now
30-day free trial. Register in 60 seconds.
Join the Community
Give a Little. Get a Lot.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Join the Community
by: DropZonePosted on 2007-08-12 at 06:05:34ID: 19679016
First, I think you are confusing a few concepts here.
om/quickst art/aspplu s/doc/ webc trlauthori ng.aspx#co mposition
1. The LoadPostData() event is only triggered when data has changed, and it is intended so that you have a chance to set the new data into the control's appropriate property. For example, the TextBox checks if the new data that comes in is different, and if so, assigns it to the Text property.
2. You should let the framework deal with IDs and ClientIDs as it knows how to guarantee they are unique. You can assign IDs to your internal controls, but you should let the framework compose the final fully qualified strings.
3. If you want your composite control to respond to events raised by its internal controls, then just use the OnBubbleEvent() event handler. This method is called by all control events, and by default they "raise" the event (i.e. bubble up) to their parent, until one is found that stops the bubbling chain.
Check out this site for more information on creating custom composite controls, and how to handle events within it:
http://samples.gotdotnet.c
-dZ.