Search code examples
wpfuser-controlswpf-controlsexpression-blend

Why don't custom events show up in Blend for a UserControl?


I have created a UserControl, and added a couple of custom routed events.

The problem is these events only show up in Properties->Events when I am manipulating an instance on the art board.

If I am editing the UserControl itself, the my custom events do not show up in the Events panel.

Is this a limitation of Blend, or a side effect of how UserControls work?


Solution

  • Think i've found my own answer:

    Sounds like its a limitation of Blend.

    According to Dr. WPF

    Blend always creates an instance of the base class as the root designer element.

    See threads here:

    http://social.msdn.microsoft.com/forums/en-US/wpf/thread/8a61c5b0-32a9-4ae2-bcf0-f0eddf0efded/

    http://social.msdn.microsoft.com/forums/en-US/wpf/thread/cbaaba59-2a90-4806-b3bd-9e4bce3741e0/

    http://social.msdn.microsoft.com/Forums/en-US/wpf/thread/7e507c2a-6ac4-4ed6-9b7f-abb15310d04f