DelphiFAQ Home Search:

How to change the cursor?

 

commentsThis article has not been rated yet. After reading, feel free to leave comments and rate it.

Question:

Is it possible to select a certain cursor (e.g. the hour glass) for a web page?

Answer:

Internet Explorer offers this since version 4 and Netscape since version 6. The relevant property is document.body.style.cursor.

You can script it as shown in the example or make it part of a CSS (makes less sense in my opinion).

Note:
IE 4 and 5 use the name 'hand' for the hand cursor, IE 6 and Netscape 6 call it 'pointer'
.

document.body.style.cursor = 'wait';

// this takes time
// calculating something

document.body.style.cursor = 'auto';

Comments:

2008-06-20, 07:50:33
anonymous  
css Cursor examples , Properties , Attribute - - http://css-lessons...mples.htm

 

 

NEW: Optional: Register   Login
Email address (not necessary):

Rate as
Hide my email when showing my comment.
Please notify me once a day about new comments on this topic.
Please provide a valid email address if you select this option, or post under a registered account.
 

Show city and country
Show country only
Hide my location
You can mark text as 'quoted' by putting [quote] .. [/quote] around it.
Please type in the code:

Please do not post inappropriate pictures. Inappropriate pictures include pictures of minors and nudity.
The owner of this web site reserves the right to delete such material.

photo Add a picture: