TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
C# Corner
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
How to Replace String in C#
Pintoo Yadav
Dec 19
2014
Code
1.8
k
0
1
facebook
twitter
linkedIn
Reddit
WhatsApp
Email
Bookmark
expand
string
str1 =
"ppp"
;
string
str2 =
"ccc"
;
string
str3 =
"kkk"
;
string
strAll3 = str1 +
", "
+str2+
", "
+str3 ;
string
[] strArray = strAll3.Split(
','
);
foreach
(
string
itm
in
strArray)
{
Console.WriteLine(itm.ToString() );
}
======
public
string
rep(
string
data) { data.Replace(
'\','
\\');
return
data; }
===
data = data.Replace(
"\\", "
\\\\");
C#
String in C#
String