I am just simply creating a web application. I wanted to insert a line break in a label
for example
label1.Text = "I AM HERE" + "\n" + "I AM NOW HERE";
I wanted to print it as
I AM HERE
I AM NOW HERE
But, it is not working... I don't know why...
I even tried
label1.Text = "I AM HERE" + '\n' + "I AM NOW HERE";
its not working.. What should I do....
Use <br /> instead of \n.
To insert line breaks use the
tags.
To insert spaces use the .
Label1.Text="First line<br/>Second line with more spaces"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With