ASP.Net Response.Write

C

csgraham74

Hi there,

ive written a function to display some returned values in a table.

I use response.write to write the values as html. My problem is that
this has stopped working correctly and i find now that i must add a
response.end at the end of my code to get this to work. the strange
thing is that it diplays the grid correctly but not the the values in
the grid.

does anyone have any ideas on this ??

i would prefer not to use response.end as this ends my code before all
other tasks have been completed.

Thanks

CG
 
G

Grant Merwitz

Rather try write it to a label on the page, that way you can place it where
you want.

So place on your page
<asp:Label id="MyLbl" runat="server" />

Then in your code, build up a string and set the label to that

string MyString = "<table><tr><td>data</td></tr></table">;
MyLbl.Text = MyString;


HTH

P.S.
Not sure why your response write stopped working
Maybe Response.Flush() would work better than Response.End - but don't see
why it stopped working in the first place
Maybe what you were trying to Response.WRite was to big?
 

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

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top