Solved

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

Posted on 2009-03-30
5
223 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

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

This article will show, step by step, how to integrate R code into a R Sweave document
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Learn the basics of if, else, and elif statements in Python 2.7. Use "if" statements to test a specified condition.: The structure of an if statement is as follows: (CODE) Use "else" statements to allow the execution of an alternative, if the …
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…

707 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

15 Experts available now in Live!

Get 1:1 Help Now