Archive

Posts Tagged ‘Tags’

Fix: The tag XXX does not exist in XML namespace ‘clr-namespace:YYY’

I just had some big trouble troubleshooting the Visual Studio / XAML compiler error message:

The tag XXX does not exist in XML namespace ‘clr-namespace:YYY’

It turned out this occurred because I had a Silverlight library with Assembly name X and default namespace X (at properties pane), but was using it from a demo project with Assembly name X (again!) and default namespace X.

If I removed the ";assembly=X" part from the XAML it worked fine, that is:

xmlns:my="clr-namespace:X"

Fixing the demo project to use Assembly name X.Demo and default namespace X.Demo (at its Properties pane), instead of having the same assembly name, now allows me to also use

xmlns:my="clr-namespace:X;assembly=X"

without problem.

Seems that when you have multiple assemblies with the same name in a project (wonder how the filesystem supports that), all of them are loaded fine and if they have classes with namespace X in them, the namespace gets classes from both assemblies (that’s why the xmlns without assembly=… works). When you specify assembly name in the XAML of a given project, it assumes you mean its own assembly, not any other referenced one with the same name.

BTW, at add references dialog I was using Projects option (to reference the output of other project in solution) and the project I was referencing was named X.Silverlight (can be named anything), I had not added reference the X assembly .dll file directly. Maybe that played its part too in the issue.

There may be other cases too that can cause this error to fire up, see:

http://social.msdn.microsoft.com/Forums/en/wpf/thread/56f933c8-a093-4c47-8e1a-cde4bb1864e9

Windows Live Writer tagging WordPress blog posts

I was delighted to see Windows Live Writer 2011 supports adding a WordPress blog nicely (pretty much automagically) and it even shows for each post a Tags input box at the bottom apart from the Categories option. It wasn’t showing a tags input box when working with Windows Live Spaces since it didn’t support such concept, but only a (limited) number of categories one could define along or replacing predefined ones (luckily Microsoft is migrating Windows Live Spaces to WordPress in a straightforward way for existing Windows Live Spaces blog authors).

Note that WordPress administration panel has online tool to convert existing categories to tags (and vice versa) which is very useful combined with the tag cloud widget, since categories are practically a tree of relations whereas tags define a full connectivity graph. Pretty sad though WordPress doesn’t have option to merge multiple preexisting categories/tags (e.g. Windows Live Spaces used to add localized and english versions for some categories) into one.

image

Version "14.0.8117.416 el" that I use (Windows Live Writer 2011) is still showing (C) 2009 in the About dialog btw:

image

And still crashes when selecting some menu options, but you can safely press "Cancel" there and keep on working fine without the app closing down which is very nice since you don’t lose any unsaved work.

image

%d bloggers like this: