Geeks With Blogs
NIEM Guy - NIEM, XML, and .NET Piecing it all together

While working on a NIEM parser library I found that you can import XML namespaces at the project level.  Previously I posted about doing this at the top of your .VB class file:

Imports <xmlns:nc="http://niem.gov/niem/niem-core/2.0">

That allows you to use the prefix nc: in LINQ queries to work with NIEM documents.  Well today I discovered you can add those at the project level.  Right click your project and go to properties.  In the properties window go to references.  Near the bottom you can type / paste your name space in (leave out the imports statement of course) and then click add user reference.  Voila!  You can now use that in any class in your project.

Import XML namespaces at the project level

 

Posted on Thursday, January 31, 2008 7:15 AM | Back to top


Comments on this post: VS 2008: Importing XML Namespaces at the project level

# re: VS 2008: Importing XML Namespaces at the project level
Requesting Gravatar...
Any idea how to do this in a c# project?
Left by Dave Horne on Feb 17, 2009 12:26 PM

Your comment:
 (will show your gravatar)


Copyright © niemguy | Powered by: GeeksWithBlogs.net