> > I'm returning a string from an xml file and trying to do something
> > like the following.
[quoted text clipped - 19 lines]
>
> vmike
I tried "<br/>" and that gives me the same error as before.
using <![CDATA[ ....]]
gives me 'This is an unexpected token. The expected token is '['. Line
1006, position 18. '
The stack trace is next to useless, just says there is a problem
reading the xml.
It works spot on if dont have the <br> in there, for example I replace
'\n' with '^' and its all good, but that doesnt help me format the
string :)
vMike - 08 Apr 2008 16:53 GMT
On 8 Apr, 16:09, "vMike" <vM...@5noerrawgespam.com> wrote:
> "JB" <jamesb...@gmail.com> wrote in message
>
[quoted text clipped - 23 lines]
>
> vmike
I tried "<br/>" and that gives me the same error as before.
using <![CDATA[ ....]]
gives me 'This is an unexpected token. The expected token is '['. Line
1006, position 18. '
The stack trace is next to useless, just says there is a problem
reading the xml.
It works spot on if dont have the <br> in there, for example I replace
'\n' with '^' and its all good, but that doesnt help me format the
string :)
Make sure you have the closing > for the the cdata function. I can
successfully open the xml file without error with a <br> in it using
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<Getter><![CDATA[return
HtmlEncode(s_tring.Value.Replace("\n","<br>"));]]></Getter>
Mike
Aidy - 08 Apr 2008 16:55 GMT
Tried using
<br/>
instead of <br/>?
On 8 Apr, 16:09, "vMike" <vM...@5noerrawgespam.com> wrote:
> "JB" <jamesb...@gmail.com> wrote in message
>
[quoted text clipped - 23 lines]
>
> vmike
I tried "<br/>" and that gives me the same error as before.
using <![CDATA[ ....]]
gives me 'This is an unexpected token. The expected token is '['. Line
1006, position 18. '
The stack trace is next to useless, just says there is a problem
reading the xml.
It works spot on if dont have the <br> in there, for example I replace
'\n' with '^' and its all good, but that doesnt help me format the
string :)
Juan T. Llibre - 08 Apr 2008 17:07 GMT
Try : <br />
Notice the space between the "r" and the slash.
i.e., <br/> is wrong, but <br /> is OK.
Also, make sure the <br /> has a pair closing tag.
Yes, I know that allegedly a paired closing tag not needed, but when dealing with .xsd files
I found out, the hard way, that .xml files will not display when the <br /> tags aren't paired.
Maybe it's the same when parsing.
Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en español : http://asp.net.do/foros/
======================================
On 8 Apr, 16:09, "vMike" <vM...@5noerrawgespam.com> wrote:
> "JB" <jamesb...@gmail.com> wrote in message
>
[quoted text clipped - 23 lines]
>
> vmike
I tried "<br/>" and that gives me the same error as before.
using <![CDATA[ ....]]
gives me 'This is an unexpected token. The expected token is '['. Line
1006, position 18. '
The stack trace is next to useless, just says there is a problem
reading the xml.
It works spot on if dont have the <br> in there, for example I replace
'\n' with '^' and its all good, but that doesnt help me format the
string :)