Try something along these lines:Code:Private Sub TextBox1_GotFocus() With TextBox1 .AutoSize = True .Left = Range("B1").Left .Top = Range("A356").Top .Width = 590 .EnterKeyBehavior = True End With End Sub Private Sub TextBox1_LostFocus() With TextBox1 .EnterKeyBehavior = False .Top = Range("A356").Top .Left = Range("B1").Left .Width = 590 .AutoSize = False ht = .Height Debug.Print ht .Height = Application.Max(171, ht) Range("A356:A375").RowHeight = (.Height / 20) ' + 0.5 .Height = Range("A356:A375").Height Do While .Height < ht Range("A356:A375").RowHeight = Range("A356").RowHeight + 0.25 .Height = Range("A356:A375").Height Loop End With End Sub




Reply With Quote
Bookmarks