Wednesday, 5 September 2018

ERROR : Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed.

"Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed." in Console Window

When you are using UpdatePanel and want to download something(either Excel or anything). You will not get error in binding Gridiview or on any other thing. To rectify it you add these lines in either Page_Load Event or on that Button Click Event:


ScriptManager scriptManager = ScriptManager.GetCurrent(this.Page);
  scriptManager.RegisterPostBackControl(this.YourButtonNameHere);
OR,

Use Trigger in Update Panel:

<Triggers>
                <asp:PostBackTrigger ControlID="YourButtonNameHere" />
</Triggers>

Happy Coding !!!

No comments:

Post a Comment

SQL Audits

1. sys.server_audits What it is: Lists all server-level audit objects . An audit is the top-level object that defines: Where to wri...