C#.NET Problem with locking of page after writing stream to window.
Posted
by godlikeskills
on Stack Overflow
See other posts from Stack Overflow
or by godlikeskills
Published on 2010-05-12T12:23:22Z
Indexed on
2010/05/12
12:24 UTC
Read the original article
Hit count: 156
c#.net
The code below works fine, the problem is the 1st two lines are appearing on screen. It basically loads the PDF but I can't see the btnAcceptProposal change name or become enabled. Tried a Thread for the load but it broke. Anyone got any ideas - it's a web application
protected void btnPDFProposal_Click(object sender, EventArgs e)
{
btnAcceptProposal.Enabled = true;
btnAcceptProposal.Text = "sss";
byte[] p = Order.Proposal;
Response.AppendHeader("content-disposition", "attachment; filename=Proposal.pdf");
Response.ContentType = "Application/pdf";
Response.Clear();
Response.BinaryWrite(p);
Response.End();
}
© Stack Overflow or respective owner