?
Solved

Tooltipstext

Posted on 2000-04-27
4
Medium Priority
?
209 Views
Last Modified: 2010-05-02
I want a tooltipstext to apper over a control, for this part it ok. But where I have some troubles, it when I want to make it multi-line tooltipstext, It seem that you can only make it a single line. If someone know how to make a tooltipstext multi-line please tell me.
0
Comment
Question by:Francois_P
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 1

Accepted Solution

by:
vbWayne earned 100 total points
ID: 2754988
'tooltips text can only be single line
'here is a walk around

'create multil line tag tips...same use as tool tips except
'that with tool tips you are restricted to one line..
'with tag tips you get multiline

'create a form with a command button (command1)
'and a label (label1)
'
'copy & paste this code into the app
'
Option Explicit

Private Sub Form_Load()
   Label1.BackColor = &H80000018
   Label1.BackStyle = 1
   Label1.BorderStyle = 1
   Label1.AutoSize = True
   Label1.Visible = True
   
End Sub

Private Sub Command1_MouseMove(Button As Integer, _
Shift As Integer, X As Single, Y As Single)
     
     Dim msg$
     msg$ = "Tag tips for the beginner." & vbCrLf
     msg$ = msg$ & "Multil Line Tag Tips Made Easy" & vbCrLf
     msg$ = msg$ & "Think of the possibilities!"
         
     
     Command1.Tag = msg$

     Label1.Caption = Command1.Tag
     Label1.Top = Command1.Top + Command1.Height
     Label1.Left = Command1.Left + Command1.Width / 2
     Label1.Visible = True
End Sub


Private Sub Form_MouseMove(Button As Integer, _
Shift As Integer, X As Single, Y As Single)
   
   Label1.Visible = False
 
End Sub
0
 
LVL 1

Expert Comment

by:PeterDobson
ID: 2754999
I'm not sure if you can, but a way around it is to set the tool tip property to "" and then fake a tool tip by setting a yellow label's visible property to true for in the mouse move event of the control in question. I use this method when creating activeX controls as the tool tips dont work!
0
 

Author Comment

by:Francois_P
ID: 2755009
Thank, this was exactly what I was looking for!
0
 
LVL 1

Expert Comment

by:vbWayne
ID: 2755034
Glad to help.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

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

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses
Course of the Month10 days, 18 hours left to enroll

770 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