。NET 2.0的ASP / VB6

问题描述 投票:0回答:2
oXML = Server.CreateObject("Msxml2.DOMDocument.4.0")
oNode = oXML.createElement("CommonCustomerSearch")
oRoot = oXML.appendChild(oNode)

正在寻找.Net 2.0中上面代码的等效项。我发现一些示例代码似乎是我想要的,但我相信它使用的是.NET_4类。我需要2.0的解决方案。

有人可以发布与上述代码行等效的.NET 2.0吗?

asp.net vb.net vb6 asp-classic
2个回答
3
投票
using System.Xml;
XmlDocument oXML = new XmlDocument();
XmlElement oNode = oXML.CreateElement("","CommonCustomerSearch","");
XmlNode oRoot = oXML.AppendChild(oNode);

0
投票

使用VB.NET将类似于...

Imports System.Xml
Dim oXML as XmlDocument = new XmlDocument
Dim oNode as XmlElement = oXML.CreateElement("","CommonCustomerSearch","")
Dim oRoot as XmlNode = oXML.AppendChild(oNode)

希望这对您有帮助...

© www.soinside.com 2019 - 2024. All rights reserved.