Home > Silverlight > HTSession on Routed Events in Silverlight

HTSession on Routed Events in Silverlight

Hi,

Welcome to my blog, today we are started with another interesting topic in silverlight, that is Routed event. In this session, we learn what are routed event, how routed event is different from general .NET events.

What is Routed events?
Routed events are events which navigate up or down the visual tree acording to their Routing Strategy. There are different routing strategy like

Tunneling The event is raised on the root element and navigates down to the visual tree until it reaches the source element or until the tunneling is stopped by marking the event as handeld.

Bubbling The event is raised on the source element and navigates up to the visual tree until it reaches the root element or until the bubbling is stopped by marking the event as handled. The bubbling event is raised after the tunneling event.To stop navigating to top element, we have mention e.Handled = true

Direct The event is raised on the source element and must be handled on the source element itself. This behavior is the same as normal .NET event.

We cannot create custom routed events in silverlight.

For further session , please follow the link for video session

Please leave your comments Routed events in Silverlight

Here is the sample Code:
RoutedEvents

-Mahender

Advertisements
Categories: Silverlight
  1. No comments yet.
  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: