User defined top level control in XAML
Posted
by luke
on Stack Overflow
See other posts from Stack Overflow
or by luke
Published on 2010-03-20T18:56:23Z
Indexed on
2010/03/20
19:01 UTC
Read the original article
Hit count: 333
A normal UserControl looks like this in XAML:
<UserControl x:Class="mynamespace.foo" ...namespaces...>
<!-- content -->
</UserControl>
I'd like to be able to define my own top level object, along the lines of:
<MyControl x:Class="mynamespace.mycontrol" ...namespaces...>
<!-- content -->
</UserControl>
Where MyControl derives from a UserControl itself.
Of course the compiler complains about "MyControl" not being found. Is there a way around this?
© Stack Overflow or respective owner