title: asp.net can't continue after response.binarywrite
body: <p>I have the following code which successfully writes a pdf to the client. The problem is that I can't get any code after this to execute. It's the last step of a wizard, and despite putting this in the ActiveStepChanged handler, it never makes it to the confirmation/final page.</p>
  
  <pre><code>                    Response.Clear()
                  Response.ContentType = Nothing
                  Response.AddHeader("content-disposition", "attachment; filename=" &amp; FileName)
                  Response.BinaryWrite(data)
                  Response.Flush()
  </code></pre>
  
  <p>Basically, there's a checkbox that the user checks if they want to download the file when they hit the Finish button. I don't want to have a separate button to download the file because users have been known to get confused and think that by pressing the download button that they've completed the necessary steps and never complete their application (we're talking about non computer literate users here). So it all works, except it doesn't make it to the confirmation step when they select that option.</p>
  
  <p>How can I ensure that processing continues after downloading the file?</p>