Solved

Hourglass in VB Script

Posted on 2003-11-18
13
1,256 Views
Last Modified: 2012-05-04
In VB script, what is the command to turn the hourglass on and turn the hourglass off?

Thanks in advance,

krameje
0
Comment
Question by:Yoink
  • 4
  • 2
  • 2
  • +4
13 Comments
 

Expert Comment

by:dustybryn
ID: 9771161
screen.mousepointer=vbhourglass 'on
screen.mousepointer= vbdefault 'off
0
 
LVL 2

Author Comment

by:Yoink
ID: 9771321
dustybryn, I am getting an "Object Required" error message.  Does screen need to be declared and set?
0
 

Expert Comment

by:dustybryn
ID: 9771747
Sorry, didn't read the question properly so I gave you the answer in VB. Have a look at the following for VBScript,

http://sourceforge.net/snippet/download.php?type=snippet&id=100396
0
Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

 
LVL 26

Expert Comment

by:EDDYKT
ID: 9771995
Try
 document.body.style.cursor="wait"

if you want to use asp

if in .vbs, I don't think you can
0
 
LVL 9

Expert Comment

by:TooKoolKris
ID: 9773130
The only way I know to do this is in IE. This will turn the cursor to the hourglass while the script is running. To turn it back change the "wait" to "default". This will create a small window and change the cursor to the hourglass for 5 seconds then close the window.

Set objIE = CreateObject("InternetExplorer.Application")
objIE.navigate "file://c:\test.htm"
objIE.left=200
objIE.top=200
objIE.height=175
objIE.width=450
objIE.menubar=0
objIE.toolbar=0
objIE.addressbar=0
objIE.statusbar=0
objIE.visible=1

Set objDocument = objIE.Document
objDocument.body.style.cursor = "wait"
Wscript.Sleep 5000
objIE.Quit
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 9776003
where are you trying to use the VBScript?  Is this for an ASP page, or in Outlook? Or perhap[s somewhere else?

AW
0
 
LVL 2

Author Comment

by:Yoink
ID: 9778153
Arthur, we are launching the VBScript files from an intranet site.  We use this site to distribute various databases within our organization.  Having the hourglass appear is a "nice to have," since some of our users are extremly click happy.
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 9778627
you might be better off issueing an Alert('This may take a while') type of message.

Just a thought.

AW
0
 
LVL 2

Author Comment

by:Yoink
ID: 9778847
Arthur, we already have a message box that appears letting the user know the download is in process, but there are the select few who lack patience.

I guess I do not understand why this is so difficult since in VBA, enabling/disabling the hourglass is a matter of using one line of code.
0
 
LVL 2

Author Comment

by:Yoink
ID: 10163756
CleanupPing,

Could you please refund the points?  I was unable to get any of the above suggestions to work.

Thanks in advance,

Yoink
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 10548729
Yoink, an EE Moderator will handle this for you.
Moderator, my recommended disposition is:

    Refund points and save as a 0-pt PAQ.
    *** several suggestions are PAQworthy

Dan Rollins -- EE database cleanup volunteer
0
 

Accepted Solution

by:
CetusMOD earned 0 total points
ID: 10598886
PAQed, with points refunded (50)

CetusMOD
Community Support Moderator
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Determine Range to Select 5 52
Add and format columns in vb6 7 63
Protecting vb6 & .Net code Obfuscation 18 152
Passing a Text Box name to a Sub 6 99
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question