xml error invalid character inside declaration



I have an xml template that I am using in visual studio 2012. It begins like this



<?xml version="1.0" encoding="utf-8" ?>


However when my code fills out the template, IE is unable to open the xml document.


enter image description here


When I open the xml doc with notepad I see that the declaration has changed from what it was in the template. It now reads:



<?xml version="1.0" encoding="utf-8"?>


The space is now missing between the " and the last '?'. When I make the change in notepad and put the space back it works. What is making this happen?


No comments:

Post a Comment