ASP.net how do I send text with enter

3

in Example.aspx.cs

protected void Page_Load(object sender, EventArgs e)
    {
      teste0989.InnerText="teste123<br>teste456<br>"
    }

in the site appears the br as text and actually wanted to enter some suggestion

    
asked by anonymous 30.06.2016 / 00:41

1 answer

4

I think what you are looking for is this:

protected void Page_Load(object sender, EventArgs e)
{
   teste0989.InnerHtml="teste123<br>teste456<br>"
}

InnerText already escapes special characters so they are displayed as text. The solution is to change% w / w%.

    
30.06.2016 / 01:21