February 28, 2021
Hot Topics:

Using Carets

  • By Scott Lloyd
  • Send Email »
  • More Articles »

Now you're all set to show that caret. Remember that you must create the caret first and you should change any settings such as blink rate before it is displayed. The prototype for the ShowCaret and HideCaret functions are as follows:

Public Declare Function ShowCaret Lib "User32" _
(ByVal hWnd As Long) As Long

Public Declare Function HideCaret Lib "User32" _
(ByVal hWnd As Long) As Long

Here the hWnd argument is the hWnd property of the form on which you'd like the cursor to blink. Picture boxes and most other controls have hWnd properties as well. Everything with carets, as you've probably noticed, is self-explanatory.

That's basically all you'll need to know about carets. In most of my tutorials I end with a sample program showcasing what I've covered, but this time I don't think I'll need to do so. If you have any questions or comments please feel free to email me at scott@talker.com.

) Copyright 1999 by Scott Lloyd. All Rights Reserved.

Page 4 of 4

This article was originally published on November 20, 2002

Enterprise Development Update

Don't miss an article. Subscribe to our newsletter below.

Thanks for your registration, follow us on our social networks to keep up-to-date