PC Review


Reply
Thread Tools Rate Thread

Assigning control tip text

 
 
kirkm
Guest
Posts: n/a
 
      15th Feb 2009

Can you add a linefeed programicably?

I'm finding chr$(13) and vblf etc. just print a square in the text.

Thanks - Kirk
 
Reply With Quote
 
 
 
 
Kenneth Hobson
Guest
Posts: n/a
 
      15th Feb 2009
It can only be one line long.
 
Reply With Quote
 
kirkm
Guest
Posts: n/a
 
      15th Feb 2009
On Sat, 14 Feb 2009 20:27:01 -0800, Kenneth Hobson
<(E-Mail Removed)> wrote:

>It can only be one line long.


Thanks... so be it !

Cheers - Kirk
 
Reply With Quote
 
kirkm
Guest
Posts: n/a
 
      15th Feb 2009
On Sun, 15 Feb 2009 05:42:36 +0000, Oorang
<(E-Mail Removed)> 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...
 
Reply With Quote
 
kirkm
Guest
Posts: n/a
 
      15th Feb 2009
On Sun, 15 Feb 2009 07:46:37 +0000, Simon Lloyd
<(E-Mail Removed)> 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
 
Reply With Quote
 
Dave Peterson
Guest
Posts: n/a
 
      15th Feb 2009
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
 
Reply With Quote
 
Kenneth Hobson
Guest
Posts: n/a
 
      15th Feb 2009
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
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
assigning numbers to text and count the text gimme_donuts Microsoft Excel Misc 2 5th Jan 2009 09:50 AM
Assigning Values to a Control Box Martin Microsoft Access Reports 2 20th Feb 2007 12:56 PM
Assigning a control source =?Utf-8?B?U0hJUFA=?= Microsoft Access Form Coding 1 7th Dec 2005 06:09 PM
Assigning text from outside source to Access form text box =?Utf-8?B?U2VsZlRhdWdodDE=?= Microsoft Access Macros 0 3rd Nov 2004 08:59 PM
Assigning text to a label in a dynamic control Steven Microsoft C# .NET 0 10th Dec 2003 08:20 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 06:59 PM.