Displaying PDF file in ASP.NET without stopping the request
<p>I am providing a PDF file to the user in an ASP.NET application.  I have included the code I am using the do this.  This works great if that's the only thing I'm doing on that request.  What I would really like to do is show provide this PDF file on Form Load without affecting any of the other stuff in the Form Load event.  Can somebody point out what I'm doing wrong in the code?  Thanks!!</p>

<pre><code>Response.Clear();
Response.Buffer = true;
Response.ContentType = file.ContentType;
Response.AddHeader("content-disposition", String.Format("attachment; filename=\"{0}\"", file.OriginalFileName));
Response.TransmitFile(Path.Combine("C:\", file.FileName));
Response.End();
</code></pre>
