Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
New line in textbox
Message
De
08/07/2005 10:03:29
Hilmar Zonneveld
Independent Consultant
Cochabamba, Bolivie
 
 
À
08/07/2005 09:58:33
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Divers
Thread ID:
01030410
Message ID:
01030426
Vues:
19
>\n is still valid for console apps. Use Environment.NewLine so it would be portable (winforms,webforms).
>
>
>TxtResult.Text = "Line 1" + Environment.NewLine + "Line2";
>
>This alternative (similar to text...endtext) is also valid:
>
>TxtResult.Text = @"Line 1
>Line2";
>
Cetin

Thanks. I suppose the "@" sign makes the compiler treat the remaining text just as it is typed?
Difference in opinions hath cost many millions of lives: for instance, whether flesh be bread, or bread be flesh; whether whistling be a vice or a virtue; whether it be better to kiss a post, or throw it into the fire... (from Gulliver's Travels)
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform