Response.Write ignores the user control.

  • Thread starter Thread starter JT
  • Start date Start date
J

JT

I'm writing a webshop for my company. I created the user header control
and placed it at the top of my form. I have server controls underneath
(TextBox, Command Button, Dropdownlist) which search for products based
on criteria. I then use "Response.Write" to print the results to an
HTML table underneath everything. (The "Datagrid Control" isn't
customizable enough) When the page returns it prints the HTML table
first and then the header user control at the bottom. How can i get
around this?

I could use "Response.Write" to print the header aswell but that would
defeat the purpose of a user control.

Thanx.
 
I'm writing a webshop for my company. I created the user header control
and placed it at the top of my form. I have server controls underneath
(TextBox, Command Button, Dropdownlist) which search for products based
on criteria. I then use "Response.Write" to print the results to an
HTML table underneath everything. (The "Datagrid Control" isn't
customizable enough) When the page returns it prints the HTML table
first and then the header user control at the bottom. How can i get
around this?

I could use "Response.Write" to print the header aswell but that would
defeat the purpose of a user control.

Thanx.

Don't mix Respose.Write and "regular asp.net controls". If you want to
output literal text, use an <asp:Literal> where you can set the Text
property.

Hans Kesting
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top