Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
HTML Encoding
Message
De
03/04/2008 11:59:07
Mike Cole
Yellow Lab Technologies
Stanley, Iowa, États-Unis
 
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Titre:
Versions des environnements
Environment:
ASP.NET
Divers
Thread ID:
01307769
Message ID:
01307878
Vues:
11
Is there a list of characters I will need to do this for, or are spaces and line breaks it?

>Mike,
>
>Use the Replace() method of the string to replace carriage returns with the break tag. You can do a similar process for spaces.
>
>
>somestring.Replace("\r", "<br/>")
>
>
>Kurt
>
>>Not sure if the title is exactly the right term...
>>
>>I have a string I am building using stringbuilder. It has several lines breaks, spaces, etc. When I try to display that on my webform it cuts out the line breaks and I'm pretty sure it's cutting out some spacing also. What is the best way to preserve this formatting?
>>
>>Thanks!
Very fitting: http://xkcd.com/386/
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform