System.Xml.XmlException: '0' is an unexpected token. ?

Hello,

In my UI automation, I have a code which gets me the inner HTML of the page. I save that in a string variable strXml. When I do a View source of that page.... the HTML is well-formed and has all the tags and double quotes etc..... as shown below:
====================================================================================
<TBODY>
<
TR>
<
TDheight="1%">
<
TABLEstyle="TABLE-LAYOUT: fixed"cellSpacing="0"cellPadding="3"width="100%"valign="top">
<
COLGROUP>
<
COLwidth="115">
<
COL> etc etc etc....
====================================================================================
BUT, when I am debugging using Visual Studio for this variable strXml it shows some extra characters on it as shown below...
====================================================================================
<tbody>\r\n<tr>

\r\n<tdheight="\"1%\">

\r\n<tablestyle="\"table-layout:fixed\"cellspacing="0"cellpadding="3"width="\"100%\"

valign="\"top\"
=======================================================================================

so, when I am using this string in my XMLDOCUMENT to LoadXML it throws an Xml.XmlException saying
FAILURE: Unhandled Exception: System.Xml.XmlException: '0' is an unexpected token. The expected token is '"' or '''. Line 4, position 48.which is for CELLSPACING Tag above.....

what I dont understand is that why is it adding \r\n and "\ and how can I preserve the format... I did a View Source and found that all the tags are ended and all attributes are enclosed by "

Thanks!

KRSNA

[5268 byte] By [XML_JR] at [2008-2-8]
# 1
It seems your problem is not directly related to UI Automation and might better be asked in the Windows Presentation Foundation forum (http://forums.microsoft.com/MSDN/ShowForum.aspx?ForumID=119&SiteID=1).

PeterDonnelly-MSFT at 2007-8-30 > top of Msdn Tech,Software Development for Windows Vista,Microsoft UI Automation...

Software Development for Windows Vista

Site Classified