ASP preload script?

They have: 330 posts

Joined: Apr 2000

I have a few forms that interact with each other but the time required to load the page seems like forever. The script being processed requires at least 11-13 seconds for telnet and processing commands so there is no way to make the page load any faster than that time. The only option I have is to give the user some type of animation to watch while waiting for it to load.

I have found preload scripts that display a while waiting for the images to load, but that doesn't work for ASP scripts.

My attempts so far:

1. Create an intercepting page that displays an animation. The page also has a form with all hidden attributes that automatically submits when the page loads. The hidden fields are just passing the previously selected data to the next page which processes the data.

The problem with this is the animation stops once the ASP scripts start on the 3rd page (2-4 seconds).

2. Create a on the referring page and when the submit button is clicked the form is hidden and the animation is displayed.

The problem here is the ASP script starts immediately so the animation is frozen as soon as it's visible.

Any suggestions would be greatly appreciated.

- I use only because it is an intranet website that uses only IE.

Mark Hensler's picture

He has: 4,048 posts

Joined: Aug 2000

Do you have buffering on? (Response.Buffer = True|False) If so, turn it off.

On the page with the telnet call.... print as much of the page as possible. Call Response.Flush, then make your telnet call, then finish the page.

Before making your telnet call, you may print a or whatever. Then after the telnet call, you can print some javascript to hide the and optionally replace it with the results of the telnet call.

May I ask what you're retrieving via telnet?

Mark Hensler
If there is no answer on Google, then there is no question.

They have: 330 posts

Joined: Apr 2000

That is a great idea! Thank you.

The telnet session is logging into network elements and obtaining provisioning settings.

Thanks again for the help.

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.