single text box to multi text box

R

rafaeljsg

Hello, I need to have a text box that show a single line when is view in the
form then if I click on it or move the mouse over it will show multiple lines
with it's data, sample:


client: john doe "single line"

now I go and over the field or click the field and I see

client:john doe
jane doe
ect. ect.
and when I move the mouse away or click the next field goes bank to:

client: john doe "single line"

can this be done with out select box is not a selection the data would be
enter like this

jonh doe, jane doe, ect.,ect.

Help and thanks

Rafael
 
A

Arvin Meyer [MVP]

You can use a MouseMove Event to display the contents of the textbox in a
ControlTip like:

Private Sub txtWhatever_MouseMove(Button As Integer, Shift As Integer, X As
Single, Y As Single)
If Not IsNull(txtWhatever) Then
txtWhatever.ControlTipText = txtWhatever
End If
End Sub

or use it to grow the textbox:

Private Sub txtWhatever_MouseMove(Button As Integer, Shift As Integer, X As
Single, Y As Single)
Me.txtWhatever.Height = 1440 ' twips which is 1 inch
End Sub

but you'll also need to put it back in the form's detail section:

Private Sub Detail_MouseMove(Button As Integer, Shift As Integer, X As
Single, Y As Single)
Me.txtWhatever.Height = 280 ' twips
End Sub

You might also use the text box's Got and Lost focus events to do the same.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top