Spinner Control

  • Thread starter Microsoft Newsserver
  • Start date
M

Microsoft Newsserver

Hi

I need a client side spinner control. But I want the increments to speed up
the longer the mouse button is pressed. Does anyone know of a free or cheap
one I can lay my hands on.

Cheers.
 
B

bruce barker

spiners are usually done wioth an animated gif. you can not change the speed.
to change speed use a static images and use a javascript timer to change them
(air code).

<img src="spinEmpty.gif" id="spinner">
<button onclick="spin(200);">start spiner</button>
<script>
var spinIndex = 0;
var numOfImages = 16;
function spin(ms)
{
spinIndex = ++spinIndex % numOfImages;
if (spinIndex == 0) if (ms > 10) --ms;
var img = document.getElementById("spinner");
img.src = "spin" + spinIndex + ".gif";
window.setTimeout("spin(" + ms + ")",ms);
}
</script>

-- bruce (sqlwork.com)
 
J

Just Me

HI

Thanks for your reply. I think perhaps I didnt make myself clear in my post,
sorry.

OK, actually, what I need is the following functionality.

I have a link/image etc and I need to be able to click on this link and hold
down the mouse button. Underneath the code needs to facilitate a number of
click events so that I can autoincrement a value without mutiple clicks.

I know spinners exist like this, infragistics has one, but it doesent do
exactly what I need, but the click hold is something that I do need.

Any idea, how I can invoke this functionality ?

Thanks
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top