Here's an interesting question...hopefully the solution isn't too obvious that I've missed it.
Basically what I would like to accomplish is this...I have a customer information page that users fill out, and at the bottom of the page is a 'submit' button. When the customer clicks this button I would like two Response.Redirects() to fire...or a similar solution. Because I would like them to then be prompted with a client download, and then immediately be redirected to another page.
I've heard of a VBScript that can accomplish this, but currently I'm stumped and not sure how to proceed. Here's about what I have so far:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If CreateConsumer() Then
Response.Redirect("/download/file.msi")
Response.Redirect("/registration/provider.aspx")
End If
End Sub
The code above obviously doesn't work...only the first Response.Redirect() is fired, so I was wondering if there's some other solution. I can't rely on Pop-ups...otherwise I'd just use onclick='javascript:window.open()' etc.
I thought about using the Server.Execute() or Server.Transfer() but to no avail.
Any and all ideas would be greatly appreciated! Thanks again so much.It is not possible in the method you have described.
You can execute the first one to get the first page then a script to start a download.I guess my question then is how to start the download without being considered a popup? What must the script contain so that a user can simply click 'submit', have the download start, and then be redirected to another page? The only other way I have been getting this to work is using the javascript:window.open() but wouldn't this method be considered a popup and therefore not a valid solution?
Thanks afterburn for clarifying for me.
Basically what I would like to accomplish is this...I have a customer information page that users fill out, and at the bottom of the page is a 'submit' button. When the customer clicks this button I would like two Response.Redirects() to fire...or a similar solution. Because I would like them to then be prompted with a client download, and then immediately be redirected to another page.
I've heard of a VBScript that can accomplish this, but currently I'm stumped and not sure how to proceed. Here's about what I have so far:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
If CreateConsumer() Then
Response.Redirect("/download/file.msi")
Response.Redirect("/registration/provider.aspx")
End If
End Sub
The code above obviously doesn't work...only the first Response.Redirect() is fired, so I was wondering if there's some other solution. I can't rely on Pop-ups...otherwise I'd just use onclick='javascript:window.open()' etc.
I thought about using the Server.Execute() or Server.Transfer() but to no avail.
Any and all ideas would be greatly appreciated! Thanks again so much.It is not possible in the method you have described.
You can execute the first one to get the first page then a script to start a download.I guess my question then is how to start the download without being considered a popup? What must the script contain so that a user can simply click 'submit', have the download start, and then be redirected to another page? The only other way I have been getting this to work is using the javascript:window.open() but wouldn't this method be considered a popup and therefore not a valid solution?
Thanks afterburn for clarifying for me.