Solved

replacing comma with carriage return line feed in asp.net 3.5 C#

Posted on 2012-12-21
2
1,351 Views
Last Modified: 2012-12-24
I have a string dscd.  In VB 2005 (windows form)  this command works OK.
        Dscd = Replace(Dscd, chr(44), Chr(13) & Chr(10))

I'm trying to convert this program to be web based using C# for asp.net 3.5

This command fails (also fails if I use + instead of &)

                    Dscd = Dscd.Replace((Char)44, (Char)13 & (Char)10);

The error message is:
The best overloaded method match for 'string.Replace(char, char)' has some invalid arguments

What would work better?
0
Comment
Question by:AlHal2
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 12

Accepted Solution

by:
HugoHiasl earned 250 total points
ID: 38712781
Dscd = Dscd.Replace(",","\r\n");
0
 

Author Closing Comment

by:AlHal2
ID: 38718277
Thanks.
0

Featured Post

Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Just a quick little trick I learned recently.  Now that I'm using jQuery with abandon in my asp.net applications, I have grown tired of the following syntax:      (CODE) I suppose it just offends my sense of decency to put inline VBScript on a…
In this Article, I will provide a few tips in problem and solution manner. Opening an ASPX page in Visual studio 2003 is very slow. To make it fast, please do follow below steps:   Open the Solution/Project. Right click the ASPX file to b…
Finds all prime numbers in a range requested and places them in a public primes() array. I've demostrated a template size of 30 (2 * 3 * 5) but larger templates can be built such 210  (2 * 3 * 5 * 7) or 2310  (2 * 3 * 5 * 7 * 11). The larger templa…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …
Suggested Courses

710 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question