By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,955 Members | 1,756 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,955 IT Pros & Developers. It's quick & easy.

Time Function --- Help.

P: n/a
Hello all,

I have a dropdownlist with more than 40 items inside. I am trying to write a
function that if the user change more than 20 items in the dropdownlist
within 4 seconds then I redirect to another page.

This action will be using in the SelectedIndexChanged.

The problem is how do I start timing?

Your help or direction to any article are big help for me.

Thank you.

Below is my SelectedIndexChanged:

Private Sub Student_SelectedIndexChanged(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
StudentList.SelectedIndexChanged

'Start timing????

End Sub 'StudentList_SelectedIndexChanged

Th****************@Hotmail.com
Nov 18 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Timing cannot be accomplished on the server side for a client action (For
this case at least). In other words, you SelectIndex change event will only
work when the index is changed and has nothing to do with timing.

You will have to time this using a JavaScript. Look for something there:

http://www.javascriptkit.com/script/cutindex1.shtml

Patrick


"le9569" <di*********@Hotmail.com> wrote in message
news:eb**************@TK2MSFTNGP09.phx.gbl...
Hello all,

I have a dropdownlist with more than 40 items inside. I am trying to write a function that if the user change more than 20 items in the dropdownlist
within 4 seconds then I redirect to another page.

This action will be using in the SelectedIndexChanged.

The problem is how do I start timing?

Your help or direction to any article are big help for me.

Thank you.

Below is my SelectedIndexChanged:

Private Sub Student_SelectedIndexChanged(ByVal sender As
System.Object, ByVal e As System.EventArgs) Handles
StudentList.SelectedIndexChanged

'Start timing????

End Sub 'StudentList_SelectedIndexChanged

Thanks.di*********@Hotmail.com


Nov 18 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.