I am looking at a source code presented on Microsoft website where a class is derived from the Adorner class and using override a new style been added to a TextBox in XAML. The code is not complete so I’m having problem on how to assign this code to the control (TextBox) on XAML.
Can an expert give me some ideas how to associated the TextBox with the inherited class?
http://msdn.microsoft.com/en-us/library/ms743737.aspx#Y1457
Regards,
Amit
I would claim that MSDN is clear enough:
You may not be able to do this in XAML unless you can get the methods invoked by the parser, e.g. via the
IListinterface. Of course you can expand XAML almost arbitrarily with markup extensions that do the necessary imperative steps for you.