当我运行一个将UTF-8转换为ISO-8859-1的XSLT时,Excel VBA将我的XML中的'TM'(商标TM)转换为'T'

我有以下的XSLT采取XML编码的UTF-8,这是最初创build的Excel,并创build相同的XML,但编码ISO-8859-1

<xsl:stylesheet version="3.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:fn="http://www.w3.org/2005/xpath-functions"> <xsl:output method="xml" version="1.0" encoding="iso-8859-1" indent="yes"/> <xsl:template match="@* | node()"> <xsl:copy> <xsl:apply-templates select="@*|node()"/> </xsl:copy> </xsl:template> </xsl:stylesheet> 

它运行良好,当我使用XMLspy来运行转换时, 变成了伟大的。 我遇到的问题是当我使用下面的Excel VBA时,谢谢Parfait,在XML中运行XSLT 变成了T

 Set xmldoc = CreateObject("MSXML2.DOMDocument") Set xsldoc = CreateObject("MSXML2.DOMDocument") Set newdoc = CreateObject("MSXML2.DOMDocument") 'LOAD XML xmldoc.async = False xmldoc.Load “path and file name & fileName.xml" 'LOAD XSL xsldoc.async = False xsldoc.Load "path and file name.xslt" 'TRANSFORM xmldoc.transformNodeToObject xsldoc, newdoc newdoc.Save “Path and file name.xml" 

我不明白为什么当Excel运行XSLT的结果是不同的。 我最初研究的是,如果Excel能够首先导出XML编码的ISO-8859-1,但似乎并不是一种select。