Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
Can you add a linefeed programicably? I'm finding chr$(13) and vblf etc. just print a square in the text. Thanks - Kirk |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
It can only be one line long.
|
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
vbLf should work fine. Code: -------------------- Sub Test() Selection.Value = "Did it " & vbLf & "work?" End Sub -------------------- -- Oorang ------------------------------------------------------------------------ Oorang's Profile: http://www.thecodecage.com/forumz/member.php?userid=129 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=64545 |
#4
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
Don't use the string $, you can use a number of ways Code: -------------------- MsgBox "This is a" & vbLf & "test for" & Chr(10) & "adding new" & vbNewLine & "Lines!" -------------------- each of the new line commands can be used on thier own or mixed as seen, but best practice would dictate that you stick with one! kirkm;231004 Wrote: Can you add a linefeed programicably? I'm finding chr$(13) and vblf etc. just print a square in the text. Thanks - Kirk -- Simon Lloyd Regards, Simon Lloyd 'The Code Cage' (http://www.thecodecage.com) ------------------------------------------------------------------------ Simon Lloyd's Profile: http://www.thecodecage.com/forumz/member.php?userid=1 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=64545 |
#5
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
On Sat, 14 Feb 2009 20:27:01 -0800, Kenneth Hobson
wrote: It can only be one line long. Thanks... so be it ! Cheers - Kirk |
#6
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
On Sun, 15 Feb 2009 05:42:36 +0000, Oorang
wrote: vbLf should work fine. Code: -------------------- Sub Test() Selection.Value = "Did it " & vbLf & "work?" End Sub -------------------- Seems the answer is No, not in a control tip text string. Hope that's right... so often there's more to it... |
#7
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
On Sun, 15 Feb 2009 07:46:37 +0000, Simon Lloyd
wrote: Don't use the string $, you can use a number of ways Code: -------------------- MsgBox "This is a" & vbLf & "test for" & Chr(10) & "adding new" & vbNewLine & "Lines!" Gotcha. But again not in the control text enviroment. Thanks - Kirk |
#8
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
Is this on a userform?
If yes: Saved from a previous post. How about just putting a label over the control and that control in a frame. Then when you mouse over the frame, it'll hide the label. But when you mouse over the control, you'll show the label. Option Explicit Private Sub CommandButton1_MouseMove(ByVal Button As Integer, _ ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single) Me.Label1.Visible = True End Sub Private Sub Frame1_MouseMove(ByVal Button As Integer, _ ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single) Me.Label1.Visible = False End Sub kirkm wrote: Can you add a linefeed programicably? I'm finding chr$(13) and vblf etc. just print a square in the text. Thanks - Kirk -- Dave Peterson |
#9
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
Similar to what Dave said, here is another Label method for a pseudo tooltip
method on a userform. Private Sub UserForm_Initialize() Label1.Visible = False End Sub Private Sub UserForm_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single) Label1.Visible = False End Sub Private Sub CommandButton1_MouseMove(ByVal Button As Integer, ByVal Shift As Integer, ByVal X As Single, ByVal Y As Single) With Label1 .Caption = "CommandButton1:" & vbCrLf & "Line2" .Left = CommandButton1.Left .Top = CommandButton1.Top - 30 .Visible = True End With End Sub |
#10
Posted to microsoft.public.excel.programming
|
|||
|
|||
Assigning control tip text
Hello kirm, Dave's suggestion is the easiest to implement. Again, if this on a UserForm you can create true multi-line ToolTips. This requires using a lot of Windows API calls to accomplish the task. Thought you might like to know. -- Leith Ross Sincerely, Leith Ross 'The Code Cage' (http://www.thecodecage.com/) ------------------------------------------------------------------------ Leith Ross's Profile: http://www.thecodecage.com/forumz/member.php?userid=75 View this thread: http://www.thecodecage.com/forumz/sh...ad.php?t=64545 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Assigning a query to a control button | Excel Programming | |||
Assigning Macro's to control buttons. | Excel Programming | |||
Assigning Multiple Macros to One ComboBox Control | Excel Programming | |||
Assigning Multiple Macros to One ComboBox Control | Excel Programming | |||
Assigning the name of a userform/control to a changing string | Excel Programming |