- Home
- Forum
- ASP.NET Web Forms (Classic)
- Download to excel using AJAX
Download to excel using AJAX
I am having an Web project, in which AJAX has been implemented at the page level. I am having an user control with a link to download an excel file using Syncfusion, which is placed inside that page. Now if i try to download the excel file it shows an error as
'Sys.WebForms.PageRequestManagerParserErrorException: Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or Server Trace is enabled.'
When i place the same user control in a page which does not have AJAX implemented, it works fine.
What should i do for that?
'Sys.WebForms.PageRequestManagerParserErrorException: Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or Server Trace is enabled.'
When i place the same user control in a page which does not have AJAX implemented, it works fine.
What should i do for that?
SIGN IN To post a reply.
3 Replies
MW
Melba Winshia
Syncfusion Team
May 8, 2007 09:54 AM UTC
Hi Eswari,
Thanks your interest in Essential XlsIO.
I created a web project in which AJAX has been implemented at the page level. But I was not able to reproduce any issues. Here is the test sample that I used to test this issue:
http://www.syncfusion.com/Support/user/uploads/AJAXEnabledWebSite1_942b65c6.zip
Here is the video clip for your reference:
http://www.syncfusion.com/Support/user/uploads/TestAjax_251a0a04.zip
Could you please take a look at the sample above and kindly let me know if you still find any problem, if not could you please modify this sample so that I can reproduce the issue? This would help me in investigating this issue further.
Thanks,
Melba
Thanks your interest in Essential XlsIO.
I created a web project in which AJAX has been implemented at the page level. But I was not able to reproduce any issues. Here is the test sample that I used to test this issue:
http://www.syncfusion.com/Support/user/uploads/AJAXEnabledWebSite1_942b65c6.zip
Here is the video clip for your reference:
http://www.syncfusion.com/Support/user/uploads/TestAjax_251a0a04.zip
Could you please take a look at the sample above and kindly let me know if you still find any problem, if not could you please modify this sample so that I can reproduce the issue? This would help me in investigating this issue further.
Thanks,
Melba
OS
Olivier Sallier
November 30, 2007 12:34 PM UTC
Hi there,
I had the same issue but managed to fix it registering my button to send full postback. The problem lies in the fact that asynchronous postbacks are sent which means that the page on the client does not expect to receive an Excel document. Here is what you have to do to register your buttons:
protected override void OnPreRender(EventArgs e)
{
ScriptManager scriptManager = ScriptManager.GetCurrent(this.Page);
//ButtonExcelExport is the button firing the Excel download
scriptManager.RegisterPostBackControl(this.ButtonExcelExport);
base.OnPreRender(e);
}
Here is an interesting acticle about the PageRequestManagerParserErrorException :
http://weblogs.asp.net/leftslipper/archive/2007/02/26/sys-webforms-pagerequestmanagerparsererrorexception-what-it-is-and-how-to-avoid-it.aspx
I found the answer to my problem here:
http://forums.asp.net/p/1040926/1596279.aspx
I had the same issue but managed to fix it registering my button to send full postback. The problem lies in the fact that asynchronous postbacks are sent which means that the page on the client does not expect to receive an Excel document. Here is what you have to do to register your buttons:
protected override void OnPreRender(EventArgs e)
{
ScriptManager scriptManager = ScriptManager.GetCurrent(this.Page);
//ButtonExcelExport is the button firing the Excel download
scriptManager.RegisterPostBackControl(this.ButtonExcelExport);
base.OnPreRender(e);
}
Here is an interesting acticle about the PageRequestManagerParserErrorException :
http://weblogs.asp.net/leftslipper/archive/2007/02/26/sys-webforms-pagerequestmanagerparsererrorexception-what-it-is-and-how-to-avoid-it.aspx
I found the answer to my problem here:
http://forums.asp.net/p/1040926/1596279.aspx
RS
Rajarajeswari S
Syncfusion Team
December 26, 2007 04:20 AM UTC
Hi,
Thanks for using Syncfusion products.
We are glad to know that you have got the solution.
Thanks a lot for giving the links.
Regards,
Raji
SIGN IN To post a reply.
- 3 Replies
- 4 Participants
-
ES Eswari
- May 7, 2007 01:49 PM UTC
- Dec 26, 2007 04:20 AM UTC