> In the object "Window" add this parameter:
>
> xmlns:test="clr-namespace:xxx;assembly=yyy"
>
> Change the xxx for the namespace of your control
> and yyy with the assembly name, or use
> xmlns:zzz="clr-namespace:xxx"
> if your control is in the same assembly. After
> this you can add your control with this code:
> <test:MyButton Name="name">text</test:MyButton>
> You can change the prefix "test" for something
> else, like "local". The final code looks like
> this:
> <Window x:Class="WpfApplication1.Window1"
> xmlns =
> "http://schemas.microsoft.com/winfx/2006/xaml/presentation"
> xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
> xmlns:test="clr-namespace:xxx">
> <test:MyButton Name="name">text</test:MyButton>
> </Window>
Ah, thanks!
--
Regards
Konrad Viltersten
--------------------------------
sleep - a substitute for coffee for the poor
ambition - lack of sense to be lazy
|