aspose file tools
The moose likes Beginning Java and the fly likes How can I make this string ok? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark "How can I make this string ok?" Watch "How can I make this string ok?" New topic
Author

How can I make this string ok?

Martin Lefebvre
Greenhorn

Joined: Nov 02, 2006
Posts: 9
Hi,
I want to define a String tmp.
Something like this, but it does'nt work...

What do I need to do to make it valid??
Thanks
Stephen Foy
Ranch Hand

Joined: Oct 17, 2005
Posts: 143
If you want a string with quotes in it, you need use a \ before the quotation.

\"


[ December 17, 2006: Message edited by: Stephen Foy ]

Stephen Foy - Microsoft Application Development Consultant
Edwin Dalorzo
Ranch Hand

Joined: Dec 31, 2004
Posts: 961
Try this:



Use a backslash to indicate that the " is part of the String and not the end of it.
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: How can I make this string ok?
 
Similar Threads
linux, tomcat and upload tmp-files
System.getProperty();
Readin a text file and cuttin the text
how many objects are available for gc?
join list of strings