Why do < and > translate into &lt; and &gt;?

I'm building a row in a table and the code looks something like this:
dim tblRow as new htmltablecell
dim var1 as string = "blah"
dim var2 as string = "blah"
tblcell.innertext = var1.tostring & "<br>" & var2.tostring

Browser this looks like this:
blah<br>blah

View source it looks like:
blah&lt;br&gt;blah

Desired result:
blah
blah

Is there a way around this?

Thanks Steve

LVL 4
Steve SiricaSenior Web Application EngineerAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

DanielSchafferCommented:
Because you're using the InnerText property. Use the InnerHTML property if you want to have HTML code in the string.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
Jeff CertainCommented:
set innerhtml instead of inner text -- innertext is translating your special characters into HTML-safe representations...
Steve SiricaSenior Web Application EngineerAuthor Commented:
So simple, yet so not obvious.

Thanks for the quick and accurate responses.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
ASP.NET

From novice to tech pro — start learning today.