View Full Version : slow down countdown with a delay

10-14-2003, 06:21 PM
hello I have typed this script, I am trying to slow down the countdown. it is counting down to 0, but it goes so fast you cant see it,

here is the code, in javascript to delay you put timeset, I thiknk but what do I do for VB/asp ???? any help would be greatful

Dim i As Decimal

i = 1
Do While i < 100
TextBox1.Text = Str(i)
i = i + 1
need to add something here maybe to slow down the countdown
If i = 100 Then
TextBox1.Text = "hello"

End If

also I am getting stuck on how to add a javascript function to an aspx page or a aspx.vb page ?????

10-14-2003, 10:32 PM
What are you trying to accomplish by delaying it? Maybe an alternate solution is available.

If anything,


<script language = "javascript">
*** Put a javascript timeout here ***


10-16-2003, 10:47 AM
thanks for getting back...

what I am trying to do is make an input box count up from 1 to 100, I can get it to count up but sadly it counts so fast you can't see the numbers go up in the input box.. so I am trying to slow theese numbers down so you can see them count up :) I was wonder if there is a way to do this in VB, well vb.net, I know in javascript you add setttime to your add function.. but I don't know how to do it in vb

hope this makes more scense of what I am trying to do :)



oh and I am still having trouble placing a javascript function in asp.net ????????? any ideas on how to do this.

10-16-2003, 11:06 AM
this sounds like a clientside action to me, so i'm with BigDaddy.

If you would like to do it serversided, then you'd need to resend the partially processed script each time, which generates a lot of trafic and is quite pointless.
I don't know .NET so i can't answer you question, but did you try to simply print it like you print other html-code ?. Or switching in and out asp-mode like BigDaddys code ?

10-16-2003, 11:16 AM
see another problem is that combining the two languages.. seems to be harder in asp.net,, I am still trying to call a javascript function from a asp.net page, and I can't work out this, but I will keep plodding on in the hope I get a break through,

thaNKS for getting back to me :)


10-16-2003, 11:27 AM