C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Communities   Interview   Jobs   Projects   Offshore Development    
Silverlight Tutorials | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Revenue Sharing |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...

New Feature: Community Sites: Create your own .NET community website and start earning from Google AdSense ! It's Free !




Event Bubbling


Posted Date: 22 Nov 2006      Total Responses: 4

Posted By: MUKESH KUMAR       Member Level: Gold     Points: 2


what is event Bubbling?
plz describe simply regarding datagrid specialy?

Regds:
Mukesh




Responses

Author: kumar    23 Nov 2006Member Level: GoldRating:     Points: 2
let us take Datagrid if u place some buttons or text boxes in datagrid if click on button then it ll raise a event,first this event goes to Datagrid .
Like this small controls raising events to parent controls is called "event bubling".


Author: kumar    23 Nov 2006Member Level: GoldRating:     Points: 2
let us take Datagrid if u place some buttons or text boxes in datagrid if click on button then it ll raise a event,first this event goes to Datagrid .
Like this small controls raising events to parent controls is called "event bubling".


Author: Sriman N Vangala    23 Nov 2006Member Level: DiamondRating:     Points: 2
Event Bubbling is nothing but events raised by child controls is handled by the parent control. Example: Suppose consider datagrid as parent control in which there are several child controls.There can be a column of link buttons right.Each link button has click event.Instead of writing event routine for each link button write one routine for parent which will handlde the click events of the child link button events.Parent can know which child actaully triggered the event.That thru arguments passed to event routine.

Some user controls are entirely self contained, for example, a user control displaying current stock quotes does not need to interact with any other content on the page. Other user controls will contain buttons to post back. Although it is possible to subscribe to the button click event from the containing page, doing so would break some of the object oriented rules of encapsulation. A better idea is to publish an event in the user control to allow any interested parties to handle the event.

This technique is commonly referred to as “event bubbling” since the event can continue to pass through layers, starting at the bottom (the user control) and perhaps reaching the top level (the page) like a bubble moving up a champagne glass.



Author: Satyanarayan SushilKumar Bajoria    20 Sep 2008Member Level: DiamondRating:     Points: 5
Hi,

Server controls like Datagrid, DataList, Repeater can have other child controls inside them. Eg., a DataGrid can have combobox inside it. These child controls do not raise their events by themselves, rather they pass the event to the container parent (which can be a datagrid, datalist, repeater), which passed to the page as 'ItemCommand' event. As the child control send their events to parent this is termed as event bubbling.

Regards
S.S.Bajoria



Post Reply
You must Sign In to post a response.
Next : image edit from a folder
Previous : How to use enter key in data grid to select the row?
Return to Discussion Forum
Post New Message
Category: .NET

Related Messages



dotNet Slackers   BizTalk Adaptors    Web Design

conference call

Contact Us    Privacy Policy    Terms Of Use