Title: Nachricht
Hi,
 
I have a problem with xpathes when I change my namespaces. msxml has a method with which you can bind prefixes to namespaces. In every xpath you can use the bound namespace prefix instead of the one used in the document. In my case, I have some different sets of namespace prefixes which can change. So the element <x:ELEMENTS> can be <ELEMENTS> or <abc:ELEMENTS>, too. The correct namespace is always defined in the XML document (like xmlns:x="http://...", xmlns="http://..." or xmlns:abc="http://...").
Is there an easy way to define a prefix at the start of parsing (like xmlns:x="http://...") and use this prefix in all expressions (like getElementsByTagName("x:ELEMENTS/x:CHILD/x:GRANDCHILD")), no matter which prefix was used in the xml file.
 
Best regards
 
Thomas Barthel

Reply via email to