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

  • Home
  • SEARCH
  • 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 3352156
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T01:59:44+00:00 2026-05-18T01:59:44+00:00

My first forray into ajax webpages is causing me some problems. My basic structure

  • 0

My first forray into ajax webpages is causing me some problems.

My basic structure is that I have a table on a page, which I want to reload without refreshing the entire page.

So on clicking a button on the page it fires of this:

function RefreshMissionsAjax() {
  //fade out the old table.
  $(clientID('MissionsDisplay')).fadeOut(500);

  //request the new value from the page (calls the GetIncompleteMissions() method in the MissionViewer.aspx.cs page)
  $.ajax({
      type: "POST",
      url: "MissionViewer.aspx/GetIncompleteMissions",
      data: "{}",
      contentType: "application/json; charset=utf-8",
      dataType: "json",
      success: function (msg) {

      $(clientID('MissionsDisplay')).html(msg.d);
      $(clientID('MissionsDisplay')).fadeIn(500);
    },
    error: function (xhr, ajaxOptions, thrownError) { 
        $(clientID('MissionsDisplay')).html('An error occured while trying to refresh the page data.');
        $(clientID('MissionsDisplay')).fadeIn(500);
    }
  });
}

And I have in the code bedind of an aspx page:

[WebMethod]
public static string GetIncompleteMissions()
{
    return GetHTMLTable();
}

This method just grabs some data, and creates a html table – nothing too fancy.

When the returned table is small (a dozen rows or less) then it works like a charm.
But when it gets larger, it takes a long long time.
At 100 rows it can take 5 minutes to render the table.
At 1000 rows I have left it for 30 minutes and nothing will happen after the fadeout.
(NB – it loads fairly quickly on the pageload, before the ajax refresh is used, so it is not the actual server side creation of the table thats the problem).

This is my first real attempt at doing something like this, so I dont know if this is the best way to do it – it was just something i pieced together that worked great when i was testing with small datasets.
Now, not so much.

Any ideas how I can make it usable?

  • 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-18T01:59:45+00:00Added an answer on May 18, 2026 at 1:59 am

    If possible, use WCF instead, it should be lot faster.

    Anyway, don’t pass the raw HTML back, have the service return minimized data in JSON format then use this data in the onsuccess event to create the table on the fly with jQuery.

    For example have the service return JSON array with 1000 items then iterate this array and add one row for each item.

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

Sidebar

Related Questions

I'm making my first foray into WPF - I have a simple form with
I am taking my first foray into PHP programming and need to configure the
Okay, so I'm doing my first foray into using the ADO.NET Entity Framework. My
First off, I am using Windows XP. I have multiple hard drives and it
First of all, I know how to build a Java application. But I have
First, let's get the security considerations out of the way. I'm using simple authentication
First off, I understand the reasons why an interface or abstract class (in the
First off if you're unaware, samba or smb == Windows file sharing, \\computer\share etc.
First off, there's a bit of background to this issue available on my blog:
First off: I'm using a rather obscure implementation of javascript embedded as a scripting

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.