Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7578185
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 30, 20262026-05-30T17:22:20+00:00 2026-05-30T17:22:20+00:00

Here’s the simplified scenario: I have a page with two sections: a search section,

  • 0

Here’s the simplified scenario:

I have a page with two sections: a search section, and a results grid that contains a list. The user checks a checkbox for each row in the results grid that they would like added to a zipfile, then clicks a button which posts back to another page that generates a zip file.

So we have:

[UpdatePanel1]
...Search Inputs...
<asp:Button ID="btnSearch" runat="server" Text="Search" OnClick="btnSearch_Click" />
[/UpdatePanel1]
[UpdatePanel2]
..Results Grid..
<asp:Button ID="btnZip" runat="server" Text="Zip" PostBackUrl="~/Zip.aspx"/>
[/UpdatePanel2]

Where the logic in Zip.aspx looks like this:

SearchPage previousPage = (SearchPage)PreviousPage;
List<Files> docs = previousPage.GetSelectedFiles();

...do logic...

Response.ContentType = "application/zip";
Response.AddHeader("Content-Length", zipBytes.Length.ToString());
Response.AddHeader("Content-Disposition", "attachment; filename=Test.zip");
Response.BinaryWrite(zipBytes);
Response.End();

The page works correctly in that you can search, which populates the results grid correctly, and you can select whichever rows and hit the “Zip” button as many times as you want and it will work correctly every time.

However, if you’ve hit the “Zip” button at least once, and go back to the search criteria and hit “Search” again, it results in this javascript error:

Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.
Details: Error parsing near 'PK'.

Looking at fiddler, it seems like the Search button is posting back to “Zip.aspx” instead of itself. Is there a way I can work around this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-30T17:22:21+00:00Added an answer on May 30, 2026 at 5:22 pm

    Looking at fiddler, it seems like the Search button is posting back to
    “Zip.aspx” instead of itself. Is there a way I can work around this?

    If that’s the case, try adding an OnClientClick handler to the SearchButton and make sure that the form action is set to the Search page itself instead of Zip.aspx

    Something like:

    function CheckPostBackURL()
    {
       document.getElementById('aspNetForm').action="Search.aspx";
    }
    

    I don’t know if it will work but that’s an idea.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Here is my problem...I have a page that loads a list of clients and
Here's my scenario - I have an SSIS job that depends on another prior
Here is a scenario: User installs .NET application that you have made. After some
Here is my code (Say we have a single button on the page that
Here is the issue I am having: I have a large query that needs
Here is the scenario: I'm writing an app that will watch for any changes
Here's the setup - I have a view that lists products. On that same
Here is my code...I have two dimensional matrices A,B. I want to develop the
here's what we have today: * NxM grid of points in 3D * we
Here's a basic regex technique that I've never managed to remember. Let's say I'm

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.