473,666 Members | 2,114 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Hour Glass Cursor not appearing

Hi,

I am doing some JavaScript calculations that can take up to one minute and
wanted an hour glass cursor to appear.

The following is not however working on IE 6 or 7

document.body.s tyle.cursor = "wait";

Many thanks in advance,

Aaron
Jan 3 '07 #1
2 3072
VK

Aaron Gray wrote:
Hi,

I am doing some JavaScript calculations that can take up to one minute and
wanted an hour glass cursor to appear.

The following is not however working on IE 6 or 7

document.body.s tyle.cursor = "wait";

Many thanks in advance,
You need to give an "execution pause", otherwise any DOM/style changes
will be applied only after you exit from the function.

function startLongProces s() {
document.body.s tyle.cursor = "wait !important";
window.setTimeo ut(longProcess, 10);
}

function longProcess() {
// do stuff
document.body.s tyle.cursor = "auto";
}

That is "hard pause" - it works universally everywhere.

Once I tried to use "soft pause", but I was getting mixed results -
mostly unsatisfactory - by different UAs. You may try it first though:

function longProcess() {
window.setTimeo ut(' document.body.s tyle.cursor = "wait !important"',
10);
// do stuff
document.body.s tyle.cursor = "auto";
}

Jan 3 '07 #2
"VK" <sc**********@y ahoo.comwrote in message
news:11******** **************@ 42g2000cwt.goog legroups.com...
>
Aaron Gray wrote:
>Hi,

I am doing some JavaScript calculations that can take up to one minute
and
wanted an hour glass cursor to appear.

The following is not however working on IE 6 or 7

document.body.s tyle.cursor = "wait";

Many thanks in advance,

You need to give an "execution pause", otherwise any DOM/style changes
will be applied only after you exit from the function.

function startLongProces s() {
document.body.s tyle.cursor = "wait !important";
window.setTimeo ut(longProcess, 10);
}

function longProcess() {
// do stuff
document.body.s tyle.cursor = "auto";
}

That is "hard pause" - it works universally everywhere.
Okay I will try this. Thanks.

Aaron
Jan 4 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
4947
by: Paul | last post by:
Just wondering if there is a way to set up a web application where the curser turns into an hour glass when the application is busy, for example processing a stored procedure on a server that takes several seconds? Thanks. -- Paul G Software engineer.
4
2941
by: Marty Cruise | last post by:
Does anyone know of an wait-type cursor that can show text beside the hourglass? I'd like to display status messages beside the hourglass while not allowing the user to click anything...
2
16300
by: diatom | last post by:
Hello, I have a custom dialog. When the user hits the 'Ok' button, I want my mouse to turn into an hourglass while its performing work - and then I want it to go back to normal afer the work is finished. In C# and Windows projects, how I can I control the look of the mouse? Thanks
1
2922
by: Mini Singh | last post by:
Hi All I am creating an application in which i need an hour glass to show that processing is going on. How do i create an Hour glass in my application. Please reply
1
1669
by: Greg Smith | last post by:
How do you set the cursor to the hour glass during long processes. The equivalent of the Windows Cursor.Current = Cursors.WaitCursor. Any help is greatly appreciated.
1
40539
by: desaiamarjeet | last post by:
I want to change the mouse pointer to hour glass in VB.NET How can i do it?
2
6972
by: =?Utf-8?B?SmlheWlu?= | last post by:
I am now trying to host a WPF control into a MFC application and get the Aero glass look on the WPF control. (Something like what Office2007 is doing to its ribbon) What should be the container of the WPF control so that I can get Aero Glass look? I tried with a System.Windows.Window, I got the Aero Glass look. But it seems that a Window must be the root element and can not be hosted in the MFC window. I also tried to use a...
1
4305
by: buntyindia | last post by:
Hi, Recently I applied a IFRAME SHIM on calendar widget. Now the problem is when ever we click on ICON that provide Calendar widget mouse pointer changed to HOUR GLASS pointer for a half second. How can we handle that It should be hand icon.. Help
2
2724
by: remya1000 | last post by:
i'm using VB.NET. when a button is clicked the utility will display an hour glass mouse pointer, and it will begin copying the Utility settings from one computer to another computer on the network. Upon completion of these steps, the mouse pointer will return to it’s default style and the program will exit. any one have any idea how to display a Hour Glass Mouse Pointer? and when that settings starts coping to another computer, how can we...
0
8356
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8871
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8781
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
7386
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6198
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
4198
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4369
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2771
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1776
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.