我一直试图从这个 xml 中找出宽度和高度:
<?xml version="1.0" encoding="utf-8"?>
<Collection MaxLevel="7" TileSize="256" Format="png" NextItemId="1" ServerFormat="Default" xmlns="http://schemas.microsoft.com/deepzoom/2009">
<Items>
<I Id="0" N="0" Source="157_images/16.XML">
<Size Width="1200" Height="900" />
<Viewport Width="1" X="0" Y="0" />
</I>
</Items>
</Collection>
但这是不可能的,xml 本身看起来不像其他 xml 文件,我使用的代码是:
path = "157.xml"
Dim document = XDocument.Load(Server.MapPath(path))
Dim Xml As String = document.ToString
Dim myallelements As XElement = XElement.Parse(Xml)