Posts: 331
Location: Ontario, Canada
|
ok.. I'm making a modification to my counting script.
But the best part is this makes the script useful.
anywho.
I'm needing to delay a while loop.
so I'm useing the falowing script as my base and just modifiying it.
HTML Code:
<html>
<head>
<title>TEMP - MUST DELETE</title>
</head>
<body>
<script language="javascript">
if(confirm("How high do you want me to count: 5?")){
countstring = 5;
number01 = 0;
while(number01 <= countstring) {
declare countingnumber value
number01 = number01 + 1;
}}else{
string04 = 0;
while(string04 = 0) {
countstring = countstring + 5;
if(confirm("How high do you want me to count: "+countstring+"?")) {
string04 = 1;
countstring = countstring;
number01 = 0;
while(number01 <= countstring) {
declare countingnumber value
number01 = number01 + 1;
}}}}
</script>
document.write("<form>");
document.write("<input type=\"text\" value=\""+countingnumber+"\">");
document.write("</form>");
</body>
</html>
now there is an error somewhere in this script because when I test the script, I can't get the second loop to start working when the user click cancel.
Anyways back to what this topic is about.
at the bottom of the script you can see where the input will be. Also you should be able to see that the value will be the string: countingnumber. This is the string I'm hope to delay in the loop. ok, now where I'm want to declare the value of countingnumber is where the declare countingnumber value text is in the script. I also want to delay the value update for one second. this is where I get stuck. I have no clue on how to delay the update in value to the countingnumber string. After I solve this problem I hope to make somthing usable out of this script. after thats done... I'll probly submit it to dynamicdrive.com and other places like that. but anyways. I would really like somebody to help me out on this one.
Thanks in Advance.
Chris Krasnichuk
__________________
Name: Chris Krasnichuk
Email Address: chris.krasnichuk@gmail.com
|