Link to home
Start Free TrialLog in
Avatar of joshuadavidlee
joshuadavidlee

asked on

How do i find the xmlns ?

I am trying to find this in some atom feeds(similiar to rss feeds):

xmlns=\"http://www.w3.org/2005/Atom\"

however it doesnt seem to be in the same spot always so how do i use xml methods to find it?
 Assume I have myXmlDoc object already.

c#

Avatar of Brian Mulder
Brian Mulder
Flag of Netherlands image

Hi joshuadavidlee,
----------

you could look into the XmlNamespaceManager, it has some methods like LookupNamespace to get the namespace in a specific prefix, i didn't get it to work right here yet

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/cpref/html/frlrfSystemXmlXmlNamespaceManagerClassLookupNamespaceTopic.asp

----------
bruintje
share what you know, learn what you don't
Avatar of Carl Tawn
You could try XPath like:

    //@*[name()='xmlns']
ASKER CERTIFIED SOLUTION
Avatar of pgloor
pgloor

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial