![]() |
illegal escape character
Any ideas why I get the following syntax error?
illegal escape character wsV1 = "\x1c"; -- Steve Remove "nospam" from email address to reply to me personally |
Re: illegal escape character
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1 Steve Rainbird schreef: > Any ideas why I get the following syntax error? > > illegal escape character > wsV1 = "\x1c"; "\\x1c", see http://mindprod.com/jgloss/regex.html#QUOTING HTH, H. - -- Hendrik Maryns ================== http://aouw.org Ask smart questions, get good answers: http://www.catb.org/~esr/faqs/smart-questions.html -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (GNU/Linux) iD8DBQFEhwhDe+7xMGD3itQRAnbNAJ9Yz8GkjNgeFmA2XD4+Ub Y1ia88ZQCeJ45A STYGDuE4yWD/CjIIv0p6dzY= =2te7 -----END PGP SIGNATURE----- |
Re: illegal escape character
"Hendrik Maryns" <hendrik_maryns@despammed.com> wrote in message
news:e67183$t0d$1@newsserv.zdv.uni-tuebingen.de... > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Steve Rainbird schreef: >> Any ideas why I get the following syntax error? >> >> illegal escape character >> wsV1 = "\x1c"; > > "\\x1c", see http://mindprod.com/jgloss/regex.html#QUOTING > > HTH, H. > > - -- > Hendrik Maryns > > ================== > http://aouw.org > Ask smart questions, get good answers: > http://www.catb.org/~esr/faqs/smart-questions.html > -----BEGIN PGP SIGNATURE----- > Version: GnuPG v1.4.2 (GNU/Linux) > > iD8DBQFEhwhDe+7xMGD3itQRAnbNAJ9Yz8GkjNgeFmA2XD4+Ub Y1ia88ZQCeJ45A > STYGDuE4yWD/CjIIv0p6dzY= > =2te7 > -----END PGP SIGNATURE----- Hendrik, thanks for helping but what I actually meant by this is the "hex 1c" like in c. I know I can have wsV1 = "\u001c"; But my manual says I can use "\x" as well. -- Steve Remove "nospam" from email address to reply to me personally |
Re: illegal escape character
Steve Rainbird wrote:
> "Hendrik Maryns" <hendrik_maryns@despammed.com> wrote in message > news:e67183$t0d$1@newsserv.zdv.uni-tuebingen.de... >> -----BEGIN PGP SIGNED MESSAGE----- >> Hash: SHA1 >> >> Steve Rainbird schreef: >>> Any ideas why I get the following syntax error? >>> >>> illegal escape character >>> wsV1 = "\x1c"; >> "\\x1c", see http://mindprod.com/jgloss/regex.html#QUOTING > > But my manual says I can use "\x" as well. > > > See http://mindprod.com/jgloss/literals.html. \x isn't supported in Java. Which manual are you using ? |
Re: illegal escape character
"Steve Rainbird" <news.nospam@rainbird.me.nospam.uk> wrote:
> thanks for helping but what I actually meant by this is the "hex 1c" like > in c. > > I know I can have > > wsV1 = "\u001c"; > > But my manual says I can use "\x" as well. Your manual is wrong! See the ultimate reference at http://java.sun.com/docs/books/jls/t...al.html#3.10.6 ("Escape Sequences for Character and String Literals"). You see: "\x" is not listed as a valid escape sequence. -- Thomas |
Re: illegal escape character
"Andy Flowers" <no.way@hose.com> wrote in message
news:SUEhg.209$s4.180@newsfe3-win.ntli.net... > Steve Rainbird wrote: >> "Hendrik Maryns" <hendrik_maryns@despammed.com> wrote in message >> news:e67183$t0d$1@newsserv.zdv.uni-tuebingen.de... >>> -----BEGIN PGP SIGNED MESSAGE----- >>> Hash: SHA1 >>> >>> Steve Rainbird schreef: >>>> Any ideas why I get the following syntax error? >>>> >>>> illegal escape character >>>> wsV1 = "\x1c"; >>> "\\x1c", see http://mindprod.com/jgloss/regex.html#QUOTING > >> >> But my manual says I can use "\x" as well. >> >> >> > > See http://mindprod.com/jgloss/literals.html. \x isn't supported in Java. > > Which manual are you using ? SAMS Teach yourself java 2 in 21 days. -- Steve Remove "nospam" from email address to reply to me personally |
Re: illegal escape character
"Thomas Fritsch" <i.dont.like.spam@invalid.com> wrote in message
news:e67egc$528$02$1@news.t-online.com... > "Steve Rainbird" <news.nospam@rainbird.me.nospam.uk> wrote: >> thanks for helping but what I actually meant by this is the "hex 1c" like >> in c. >> >> I know I can have >> >> wsV1 = "\u001c"; >> >> But my manual says I can use "\x" as well. > Your manual is wrong! > See the ultimate reference at > http://java.sun.com/docs/books/jls/t...al.html#3.10.6 > ("Escape Sequences for Character and String Literals"). You see: "\x" is > not listed as a valid escape sequence. > > -- > Thomas > So it seems. Thanks everybody at least that explains it. -- Steve Remove "nospam" from email address to reply to me personally |
Re: illegal escape character
Steve Rainbird wrote:
> SAMS Teach yourself java 2 in 21 days. > SAMS sux! ;) |
| All times are GMT. The time now is 07:38 AM. |
Powered by vBulletin®. Copyright ©2000 - 2013, vBulletin Solutions, Inc.
SEO by vBSEO ©2010, Crawlability, Inc.