need short replace example

  • Thread starter Thread starter July Hollow
  • Start date Start date
J

July Hollow

Hi!...

If i have an string like this "hello world" (with the
quotes) who can i make a replace the quotes by the same in
HTML?

I try this:

word.Replace(""", """);

but shows me an error...
Thanks.
July.
 
word = word.Replace ( "\"", """ );

if your wanting to convert strings of text though, check out the HTML
encoder, which does all this sort of thing for you.

Dan.


Hi!...

If i have an string like this "hello world" (with the
quotes) who can i make a replace the quotes by the same in
HTML?

I try this:

word.Replace(""", """);

but shows me an error...
Thanks.
July.
 
July Hollow said:
Hi!...

If i have an string like this "hello world" (with the
quotes) who can i make a replace the quotes by the same in
HTML?

I try this:

word.Replace(""", """);

but shows me an error...

You need to escape the double quote:

word = word.Replace ("\"", """);
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top