473,379 Members | 1,257 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,379 software developers and data experts.

Dynamic updates

I need to know if I should use asp.net or Java for this. I would like to use
asp in general.

I need to have a function check to see if a variable is true or false and
update an icon. But I want it to either check when updated or every 3
seconds. I suppose it has to be somewhat client side scripting but is there a
way around this. As of now I use IFrames whith a refresh of 10 seconds, any
less will cause it to timeout. I kind of want it real-time or very near. It's
kind of like a status page for information in a database. Any suggestions?

Thanks
Jul 21 '05 #1
2 1067
<html><body onload="checkImage();">
<script type="text/javascript">
function checkImage() {
document.images['x'].src='image.asp';
window.setTimeout('checkImage()',300);
}
</script>
<img name="x" src="">
</body>
</html>
Where image.asp looks like:

<%
If Second(Time) Mod 2 = 0 Then
sImage = "even.gif"
Else
sImage = "odd.gif"
End If
Response.Redirect sImage
%>

Ray at work

"Dev880" <De****@discussions.microsoft.com> wrote in message
news:D5**********************************@microsof t.com...
I need to know if I should use asp.net or Java for this. I would like to
use
asp in general.

I need to have a function check to see if a variable is true or false and
update an icon. But I want it to either check when updated or every 3
seconds. I suppose it has to be somewhat client side scripting but is
there a
way around this. As of now I use IFrames whith a refresh of 10 seconds,
any
less will cause it to timeout. I kind of want it real-time or very near.
It's
kind of like a status page for information in a database. Any suggestions?

Thanks

Jul 21 '05 #2
Whoops. Make that 3000, not 300 in setTimeout. :]

Ray at work

"Ray Costanzo [MVP]" <my first name at lane 34 dot commercial> wrote in
message news:uo**************@TK2MSFTNGP12.phx.gbl...
<html><body onload="checkImage();">
<script type="text/javascript">
function checkImage() {
document.images['x'].src='image.asp';
window.setTimeout('checkImage()',300);
}
</script>
<img name="x" src="">
</body>
</html>
Where image.asp looks like:

<%
If Second(Time) Mod 2 = 0 Then
sImage = "even.gif"
Else
sImage = "odd.gif"
End If
Response.Redirect sImage
%>

Ray at work

"Dev880" <De****@discussions.microsoft.com> wrote in message
news:D5**********************************@microsof t.com...
I need to know if I should use asp.net or Java for this. I would like to
use
asp in general.

I need to have a function check to see if a variable is true or false and
update an icon. But I want it to either check when updated or every 3
seconds. I suppose it has to be somewhat client side scripting but is
there a
way around this. As of now I use IFrames whith a refresh of 10 seconds,
any
less will cause it to timeout. I kind of want it real-time or very near.
It's
kind of like a status page for information in a database. Any
suggestions?

Thanks


Jul 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

19
by: Christian Fowler | last post by:
I have a VERY LARGE pile of geographic data that I am importing into a database (db of choice is postgres, though may hop to oracle if necessary). The data is strictly hierarchical - each node has...
14
by: Ina Schmitz | last post by:
Hello, I would like to get the logical and physical reads for every sql statement executed. Thatfore, I used the command "db2 get snapshot for dynamic sql on <mydatabase>". There, I could see...
2
by: theComputer7 | last post by:
I cut down the code to make this half way understandable... I have read Data Grid girls caution about over use of dynamic controls. I truly believe what I am doing requires dynamically inserted...
1
by: caiaphas | last post by:
hi, Im trying to make a trigger that monitors the deletes and updates on a table. I will use this design for many tables so Im trying to make it as dynamic as posible. Im trying to build a...
7
by: Ronald S. Cook | last post by:
I've always been taught that stored procedures are better than writing SQL in client code for a number of reasons: - runs faster as is compiled and lives on the database server - is the more...
5
by: Ronald S. Cook | last post by:
I've read a few posts on the stored procedure vs dynamic sql debate. I ran a few performance test for myself and it appears to be a wash. Given that, I'm leaning toward dynamic sql mostly...
2
by: Snichols | last post by:
I am attempting a set record ID to make a number field dynamic. 1st - doe the field have to be an "autonumber" or can it be a number field. Also, when I set the query in the stringobject, it gives...
0
by: tickle | last post by:
Need to convert this PL/SQL script to Dynamic SQL Method 2 * copybook - celg02u3.sql SIR 24265 * * updates dt_deny for all rows in * * ...
1
by: markla | last post by:
Hi, Can someone help me understand why for the code below, when added as a "FieldTemplate" in Dynamic Data, and rendered for a field, does not trigger the "test" function and hence update the...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.