I have two javascript message boxes - when both of these boxes fire my webpage jumps to the top of the page.
Can there be some code implemented which prevents the webpage from jumping to the top of the page when the message box fires?
Thanks
Dim strscript As String = "<script>alert('Request Submitted');window.location.href='Login.aspx'</script>"
If Not ClientScript.IsClientScriptBlockRegistered("clientscript") Then
ClientScript.RegisterStartupScript(Me.GetType(), "clientscript", strscript)
End If
Dim message As String = "Please confirm the request meets specified criteria"
Dim sb As New System.Text.StringBuilder()
sb.Append("<script type = 'text/javascript'>")
sb.Append("window.onload=function(){")
sb.Append("alert('")
sb.Append(message)
sb.Append("')};")
sb.Append("</ ...
Go to the complete details ...