Click here to Skip to main content
15,171,439 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
XmlDocument doc = new XmlDocument();
XMLNode x = doc.SelectNodes(xpath)

ASP Page
Getting x in classic asp page
1)How to loop through the items with out using MSXML2 references??
2)XMLNode object cannot be accumulated to a same sort type object in classic asp. I miss SelectNodes();selectSingleNode() functions
3)Depending no:of xml nodes html is built

Please comment on (2) with out using MSXML2/MSXML? references

What I have tried:

ASP Page
set obj = Server.CreateObject("Msxml2.DOMDocument")
1)obj.SelectNodes("Contact") - returns XMLNode sort of Type
2)obj.selectSingleNode("DateApplied") - returns XMLNodeList soft of type

Replace all functions with similar do

TypeCast/similar objects for XMLNode not available in classic asp

1 solution

You're comparing two completely different technologies that support completely different objects. .net is far more mature than classic ASP so it's natural that its inbuilt XML handling is going to be better. ASP classic can only do things by using COM objects which is what MSXML2.DOMDocument is. .net uses .net classes in namespaces which is what XmlDocument is. If you don't want to use MSXML2.DOMDocument then you'd have to use some other COM object that supports the traversal of XML, or write your own that mimics XmlDocument. If you're using old tech like ASP then you need to use the old framework objects too.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900