XML Notepad 2007 Transform Error

Posted by OmegaMan at March 26, 2007

Category: Bug Reports

Update: Removing the DocType entity in the xslt resolves this problem.

Upon downloading the latest Xml Notepad, I decided to to a quickie transformation. When I did that I got this error message:

Error Transforming XML

XSLT compile error. For security reasons DTD is prohibited in this XML document. To enable DTD processing set the ProhibitDtd property on XmlReaderSettings to false and pass the settings into XmlReader.Create method.

Is this a problem with my XSLT or is it a problem with the editor. Note I can transform in Visual Studio with no problems and my .Net code that consumes the xml and XSLT transforms flawlessly…

Steps to reproduce, note for #4 one will need to create a file for the XSLT.

  1. Select New File button to clear. (Important)
  2. Paste the xml into the Xml area.
  3. Click on the XSL output.
  4. Browse to the XSLT location.
  5. Click Transform.
<?xml version="1.0"?>



    <Phase ID="-1" Status="Success">


        <Account ID="86753" Status="Success">


            <Portfolio ID="8675309" Type="A" Description="" Target="N/A" Status="Success">


                <Report Bytes="1121875" Directory="S:Working DirectoryBalances_03232007.txt">(1121875) written for S:Working DirectoryBalances_03232007.txt</Report>









<?xml version=”1.0encoding=”utf-8?>
<!DOCTYPE xsl:stylesheet [
<!ENTITY nbsp “ >
]><xsl:stylesheet version=”1.0
<xsl:output method=”htmlversion=”4.0encoding=”UTF-8indent=”yesmedia-type=”text/html“/>
<xsl:template match=”MigrationReport/Completed> <html>
<h1 style=”background: #708090; color: #F4F5E9; font-variant: small-caps; letter-spacing: 4px; margin-left: 10%; margin-right: 10%; padding-bottom: 10px; padding-top: 10px; text-align: center; text-decoration: none;>Migration Report</h1>
<xsl:apply-templates select=”Phase“/>
<xsl:template match=”Phase><hr/>
Phase <xsl:value-of select=”@ID“/>
disable-output-escaping=”yes>&nbsp;&nbsp;</xsl:text>(<xsl:value-of select=”@Status“/>)
</h3><xsl:apply-templates select=”Accounts/Account“/><!– <xsl:apply-templates select=”ID“/>
<xsl:apply-templates select=”attributes“/>>


<xsl:template match=”Account>
<fieldset style=”margin-left: 9%;>
<xsl:value-of select=”@ID“/><xsl:text
disable-output-escaping=”yes>&nbsp;&nbsp;</xsl:text>(<xsl:value-of select=”@Status“/>)
<xsl:apply-templates select=”Portfolios/Portfolio“/>


<xsl:template match=”Portfolio>
<li style=”vertical-align: middle;>

<div style=”padding-left: 5px;padding-right: 8px;font-size: x-small;>

<fieldset style=”margin-top: 5px;margin-bottom: 6px;>
<xsl:value-of select=”@ID“/><xsl:text
disable-output-escaping=”yes>&nbsp;&nbsp;</xsl:text>(<xsl:value-of select=”@Status“/>)
<xsl:apply-templates select=”Reports/Report“/>


<xsl:template match=”Report>

<xsl:call-template name=”links>
<xsl:with-param name=”strselect=”@Directory“/>
<xsl:value-of select=”.“/>


<xsl:template name=”links>
<xsl:param name=”str“/>
<xsl:if test=”string-length($str)>‘0’”>
<a href=”file:///{$str}>View</a>



Leave a comment

(required) (will not be published)

This site uses Akismet to reduce spam. Learn how your comment data is processed.

  • Recent Comments

    Thanks for this simple yet delightful code....
    Hey guys I'm having the same problem as Netanel KL { “Error HRESUL...
    Soluciono el problema con el primero (First step solved it for me)....
    Thank you! I was looking for this. You save my day!...
    Thank you! This was a big help. My requirement was a little differen...
    Thanks, after a small path adjustment it worked for Visual Studio 2015...
    Good call!...
    Thank you .. this helped...
    How about when you have a long string with no space? I tried it and it...
    Thank you, I ran into this same issues with Visual Studio 2015 after i...
  • Blog Stats

    • 138,464 hits