Browse DevX
Sign up for e-mail newsletters from DevX

Tip of the Day
Language: Visual Basic
Expertise: Beginner
Aug 6, 1997



Building the Right Environment to Support AI, Machine Learning and Deep Learning

Create "Tag Tips"

Use the Tag property and the MouseMove event to create "tag tips" which look like tool tips. Create a label to be used as the tool tip box and set its visible property to False, and its AutoSize property to True. Then add this code to the MouseMove event of the control to which you are adding tag tip text:
 Label1.Caption = Command1.Tag
Label1.Top = Command1.Top + Command1.Height
Label1.Left = Command1.Left + Command1.Width / 2
Label1.Visible = TRUE
Set the Tag property of the control to the text you want to display as the tag tip:
 Command1.TAG = "This is the TAG TIP"
Add this to the MouseMove event of the form. It turns off the tag tip when you move your mouse off the control:
 Label1.Visible = FALSE
Robert Meyering
Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.



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