how to refresh page after save dialog
I using save dialog class from dot net to open a a save dialog to let user save file to the local machine. But after that, my page stand there and do nothing for the rest of my process. I use below code to open a save dialog
Private Sub Browse_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Browse.Click
Response.Clear()
Response.AddHeader("Content-Disposition", "attachment; filename=A.txt")
Response.AddHeader("Content-Length", file.Length.ToString())
Response.ContentType = "application/octet-stream"
Response.BinaryWrite(file)
Response.Flush()
Response.Close()
end sub
the html code is below:
<asp:Button id="Browse" runat="server"></asp:Button>
but after the file is save to loca machine and the save dialog is close, my page no response at all. May I know how to do a postback to the page after the save dialog is close. Or any way to continue the rest of my code?
Thanks so much.
|