在vb.net中的response.redirect之前缓冲

时间:2018-03-28 02:29:34

标签: vb.net

在我继续response.redirect到另一个页面之前,有人知道如何进行缓冲吗?

以下是我已完成的示例代码。

Dim msg = String.Format("<script language='javascript'>alert('Payment Success');</script>")
context.Response.Write(msg)
context.Response.Redirect("Index.aspx")

1 个答案:

答案 0 :(得分:0)

有必要在javascript中进行重定向。

isDisable($index)

或者,您可以使用Dim msg = String.Format("<script language='javascript'>alert('Payment Success'); window.location.replace('Index.aspx'); </script>") context.Response.Write(msg) (请参阅How do I redirect to another webpage?

相关问题