I've been trying to get the cursor (in IE5.5) to change to an hourglass and then back to the default after a long process.
The method below is called with cursorType = "wait" on the pressing of a button - at the same time an asynchronous call is made to a 3rd party ActiveX COM object to start the process (which is a call to a remote computer). When the process is complete, the ActiveXControl calls a JavaScript event handler which in turn calls setCursor with cursorType = "default".
This sort of works, but the change from hourglass back to the default arrow doesn't become visible until the user moves the mouse. This rather defeats the point of the hourglass. The user is patiently staring at the screen waiting for it to change back to the default pointer... Little do they know that the process has finished but the cursor won't change until they nudge the mouse!
Any ideas?
function setCursor(cursorType) {
if (document.all) {
for (var i=0; i < document.all.length; i++) {
document.all(i).style.cursor = cursorType;
}
}
}
The method below is called with cursorType = "wait" on the pressing of a button - at the same time an asynchronous call is made to a 3rd party ActiveX COM object to start the process (which is a call to a remote computer). When the process is complete, the ActiveXControl calls a JavaScript event handler which in turn calls setCursor with cursorType = "default".
This sort of works, but the change from hourglass back to the default arrow doesn't become visible until the user moves the mouse. This rather defeats the point of the hourglass. The user is patiently staring at the screen waiting for it to change back to the default pointer... Little do they know that the process has finished but the cursor won't change until they nudge the mouse!
Any ideas?
function setCursor(cursorType) {
if (document.all) {
for (var i=0; i < document.all.length; i++) {
document.all(i).style.cursor = cursorType;
}
}
}