I think the issue you are seeing is because you dont set the MemoryStream
back to its initial position before passing it into the Dom?
ms.Seek( 0, SeekOrigin.Begin );
"rasx" <rasx (an email account) at songhaysystem.com> wrote in message
news:FE3CA3EB-9A73-4351-B00D-26FC04469002@microsoft.com...[color=blue]
> The short answer to the earlier post is, 'Don't use a MemoryStream object
> with an XmlWriter.' The expected results are received in my case when an
> HttpContext.Response.OutputStream is used instead.
> --
> Bryan, Emperor of String.Empty
>
http://songhaysystem.com
>
>
> "dickster" wrote:
>[color=green]
>> I have seen that empty rectangle before- seems like default behaviour
>> -why I have no idea.
>>
>> There is a parameter "encoderShouldEmitUTF8Identifier" (type Boolean)
>> as one of the options on the constructor of the
>> System.Text.UTF8Encoding
>>
>>
>> So add these 2 lines
>> --------------------------------------------------------
>> System.text.UTF8Encoding enc;
>> enc = New System.text.UTF8Encoding(False);
>> --------------------------------------------------------
>>
>> And change your code to this
>> --------------------------------------------------------
>> MemoryStream ms = new MemoryStream();
>> XmlTextWriter xw = new XmlTextWriter(ms,enc);
>> --------------------------------------------------------
>>
>> Dickster
>>
>>[/color][/color]