views:

18

answers:

1

I've found that in order to use PRISM's classes in XAML you need to import namespace in that way: xmlns:cal="http://www.codeplex.com/CompositeWPF" this way is new to me, so I wanted to know, how hyperlink could be alias of usual notation of namespace import? so the intellisence knows in which assembly it should search this component? Thanks!

+1  A: 

If you look in the AssemblyInfo.cs file for an assembly you are interested in, there is typically an assembly attribute that maps a URI to a CLR namespace. Here's an example:

[assembly: XmlnsDefinition("http://www.dummy.com/Stuff",
                           "Dummy.Common.UI")]

You can combine multiple mappings to the same URI as well:

[assembly: XmlnsDefinition("http://www.dummy.com/Stuff",
                           "Dummy.Common.UI")]
[assembly: XmlnsDefinition("http://www.dummy.com/Stuff",
                           "Dummy.Common.UI.Controls")]

These can even cross assemblies... you can use the same URI to map namespaces from multiple assemblies.

It's helpful to use this yourself as well! It's pretty convenient.

Anderson Imes
Thanks for explanation!
Andrey Khataev

related questions