473,387 Members | 1,669 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

need short replace example

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.
Nov 15 '05 #1
3 2752
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.
"July Hollow" <an*******@discussions.microsoft.com> wrote in message
news:12*****************************@phx.gbl...
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(""", "&quot;");

but shows me an error...
Thanks.
July.
Nov 15 '05 #2
July Hollow <an*******@discussions.microsoft.com> wrote:
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(""", "&quot;");

but shows me an error...


You need to escape the double quote:

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

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 15 '05 #3
Thanks to both...
Regards.
July
-----Original Message-----
July Hollow <an*******@discussions.microsoft.com> wrote:
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 ("\"", """);

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
.

Nov 15 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

11
by: Jim | last post by:
Hi, I keep getting form results emailed to me that would indicate a form from my web site is getting submitted with all fields blank or empty, but my code should preventing users from proceeding...
9
by: sk | last post by:
I have an applicaton in which I collect data for different parameters for a set of devices. The data are entered into a single table, each set of name, value pairs time-stamped and associated with...
19
by: James Fortune | last post by:
I have a lot of respect for David Fenton and Allen Browne, but I don't understand why people who know how to write code to completely replace a front end do not write something that will automate...
11
by: Ben Collingsworth | last post by:
Anyone have some efficient source code for implementing a ring buffer?
99
by: Glen Herrmannsfeldt | last post by:
I was compiling a program written by someone else about six years ago, and widely distributed at the time. It also includes makefiles for many different systems, so I know it has been compiled...
48
by: Chad Z. Hower aka Kudzu | last post by:
A few of you may recognize me from the recent posts I have made about Indy <http://www.indyproject.org/indy.html> Those of you coming to .net from the Delphi world know truly how unique and...
8
by: moondaddy | last post by:
I'm writing an app in vb.net 1.1 and I need to parse strings that look similar to the one below. All 5 rows will make up one string. I have a form where a use can copy/paste data like what you...
11
by: Peted | last post by:
Im using c# 2005 express edition Ive pretty much finished an winforms application and i need to significantly improve the visual appeal of the interface. Im totaly stuck on this and cant seem...
2
by: jasiu85 | last post by:
Hey, Please take a look at the code of the two threads below: COMMON_DICT = {} def thread_1(): global COMMON_DICT local_dict = prepare_dict() COMMON_DICT = local_dict
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.