Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Tooltipstext

Posted on 2000-04-27
4
Medium Priority
?
213 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

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
Enums (shorthand for ‘enumerations’) are not often used by programmers but they can be quite valuable when they are.  What are they? An Enum is just a type of variable like a string or an Integer, but in this case one that you create that contains…
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
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…
Suggested Courses

618 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