If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

RoutedEvent vs AttachedEvent

Hello, I've managed to setup an example working for both RoutedEvent and AttachedEvent but it appears the difference between the two is just syntactical as "RoutedEvent" handler can be declared in XAML in same syntax as "AttachedEvent".

I understand phylosophical difference between DependencyProperty and AttachedProperty. I understand perfect "Grid.Row" is an "Attached Property" that it's not a property of "TextBox" itself for instance. I understand analogy when this concept extended to "Events". However - what's confusing is the SYNTAX: you can define an event handler to a RoutedEvent the same way/syntax as you would with AttachedEvent.

Here's an example, I have MainWindow.xaml the top level form, containing user control MiddleChild.xaml, which in turn contain GrandChild.xaml (where one "RoutedEvent" and one "AttachedEvent" is declared)

All good so far. Now, here comes the confusing part, in MainWindow.xaml - I use the same syntax to setup event handler for both "RoutedEvent" and "AttachedEvent" - this lead me to the question, really what's difference between RoutedEvent and AttachedEvent?!

* The Perfect Platform for Game Developers: Android
Developing rich, high performance Android games from the ground up is a daunting task. Intel has provided Android developers with a number of tools that can be leveraged by Android game developers.

* The Best Reasons to Target Windows 8
Learn some of the best reasons why you should seriously consider bringing your Android mobile development expertise to bear on the Windows 8 platform.