maxx_daddy
Board Regular
- Joined
- Dec 3, 2010
- Messages
- 74
hi all,
I have a userform that has 19 textboxes on it. I would like to enlarge the textbox when entered so as to give enough room to type a multi line answer as needed. My question is.... is there a way to reposition the text boxes below the active text box dynamically, say based on the top or bottom of the textbox above? otherwise the only way I can see to do this is this
for every textbox.
thanks for looking,
Maxx_daddy (Maxx's daddy)
I have a userform that has 19 textboxes on it. I would like to enlarge the textbox when entered so as to give enough room to type a multi line answer as needed. My question is.... is there a way to reposition the text boxes below the active text box dynamically, say based on the top or bottom of the textbox above? otherwise the only way I can see to do this is this
Code:
Private Sub TextBox1_Enter() With TextBox1
.Top = 5
.Height = 100
End With
With TextBox2
.Top = 110
.Height = 20
End With
With TextBox3
.Top = 135
.Height = 20
End With
With TextBox4
.Top = 160
.Height = 20
End With
With TextBox5
.Top = 185
.Height = 20
End With
With TextBox6
.Top = 210
.Height = 20
End With
With TextBox7
.Top = 235
.Height = 20
End With
With TextBox8
.Top = 260
.Height = 20
End With
With TextBox9
.Top = 285
.Height = 20
End With
With TextBox10
.Top = 310
.Height = 20
End With
With TextBox11
.Top = 335
.Height = 20
End With
With TextBox12
.Top = 360
.Height = 20
End With
With TextBox13
.Top = 385
.Height = 20
End With
With TextBox14
.Top = 410
.Height = 20
End With
With TextBox15
.Top = 435
.Height = 20
End With
With TextBox16
.Top = 460
.Height = 20
End With
With TextBox17
.Top = 485
.Height = 20
End With
With TextBox18
.Top = 510
.Height = 20
End With
With TextBox19
.Top = 535
.Height = 20
End With
End Sub
Private Sub TextBox1_Exit(ByVal Cancel As MSForms.ReturnBoolean)
With TextBox1
.Height = 20
End With
End Sub
thanks for looking,
Maxx_daddy (Maxx's daddy)