tags:

views:

171

answers:

1

I have a page and I want to insert 'Some text' on that page, but right after the form tag gets rendered.

Protected override Render renders text inside body tag, but outside the form tag.

Now I have a code that renders like: <body>Some text<form>Rest of the page
And I want: <body><form>Some text, Rest of the page

Is there any way that I can render the text right after the form taggets rendered?

Hope it is clearer.
Thanks.

+1  A: 

Why not just add a control first in the form?

Page.Form.Controls.AddAt(0, new LiteralControl("Hello world."));
Guffa
So simple and I was trying something a lot more complex.Didn't though of thatThank you.Actually, Page.Form.Controls.AddAt(0, new LiteralControl("Hello world."));You misstyped Controls (for future reference).
lopkiju
Thanks. I'll make the correction. :)
Guffa