Quicker Ways to Set the MousePointer

Category:
Miscellaneous
Type:
Snippets
Difficulty:
Beginning
Author:
Alex Kail

Version Compatibility: Visual Basic 6, Visual Basic 5

More information:
Here are two ways to save typing time when setting the mouse pointer property. The first a Property Let/Get procedure pair, lets you set the Mouse property to a constant such as vbHourglass or vbArrow, rather than typing Screen.MousePointer = vbHourglass.

The second, a pair of functions called MouseBusy and MouseNormal are even quicker, if you typically only use vbDefault and vbHourglass for your MousePointers. Just type MouseBusy when you want an hourglass and MouseNormal when you want the default.

Instructions: Copy the declarations and code below and paste directly into your VB project.

Declarations:

Code: