Solved

How do I dynamically rewrite a vbs ASP page without reloading the whole thing?

Posted on 2009-03-30
5
226 Views
Last Modified: 2012-05-06
Hi Experts

I have a quick and dirty vbs asp page which creates my grid layout to display some dynamic data

I expect to use js GetElementByID to set the value of each element from the variables I will receive from the server at regular intervals

The thing that's making my hair itch is I have no clue how to implement the calls to the server to get the data WITHOUT reloading the whole page. I want this layout to appear static and not have to reload itself (otherwise I could just have the vbs create the html on the fly from the source data serverside)

The reason for this is that it's some pretty hefty WMI data, and takes a couple of seconds to poll for it, yet I want my page to look smooth, and only the displayed data within it to change

All I want the periodic script to do using a setTimeout timer is get a bunch of data from the server(this data changes all the time), and write the values in the corresponding element

The vbs to get/create the data is already done
The js to write a variable to an html element is straightforward

I just need the bit in the middle...  :P
0
Comment
Question by:FireW0lf
  • 3
  • 2
5 Comments
 
LVL 4

Author Comment

by:FireW0lf
ID: 24017700
I had an idea to use a "hidden" iframe which would regularly refresh itself, grab the new data, and then use javascript parent methods to write the data to the relevant elements, but this feels a bit kludgy

Is there a cleaner method?
0
 
LVL 19

Accepted Solution

by:
daveamour earned 250 total points
ID: 24017708
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24017713
Interestingly your first idea was used by Microsoft but has since been dropped!
0
 
LVL 4

Author Comment

by:FireW0lf
ID: 24018008
Thanks daveamour

Haven't tried it yet, but the code looks very straightforward so I dont envision any issues implementing this. You saved me potentially a wasted day or two

Yep - much better than my (and Mses apparently :P ) messy idea

Points awarded!
0
 
LVL 19

Expert Comment

by:daveamour
ID: 24018052
Thanks for the points
0

Featured Post

DevOps Toolchain Recommendations

Read this Gartner Research Note and discover how your IT organization can automate and optimize DevOps processes using a toolchain architecture.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

It is a general practice to get rid of old user profiles on a computer  in a LAN environment. As I have been working with a company in a LAN environment where users move from one place to some other place at times. This will make many user profil…
This article discusses the difference between strict equality operator and equality operator in JavaScript. The Need: Because JavaScript performs an implicit type conversion when performing comparisons, we have to take this into account when wri…
The viewer will learn how to count occurrences of each item in an array.
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now