retry/cancel popup while refreshing the page-ASP.NET C#
I'm having an image button as a templatefield inside a gridv开发者_开发问答iew.On clicking of the image button i will retrieve a pdf document from a folder location as byte array.The method will return null if the document is not available.after that if we try to refresh the page ,it throws retry/cancel popup.
The grid is inside an update panel and the update panel is having postback trigger for that image button.
Please help me on this.
Thanks.
For this issues, you have to redirect to that particular page after clicking on that image button from the grid. Please use following code after your code.
ScriptManager.RegisterStartupScript(Page, this.GetType(), "Close", "javascript:window.location='" + Request.Url + "';", true);
精彩评论