I'm grateful for the following code a member supplied to help me string together multiple cells with unique formatting into one cell while retaining the precise source cell formatting (including spacing), but when I use it the target cell (A11) will not autofit the row height. I could adjust the row manually, but it is a part of a series of called macros. Can anyone suggest code to insert within my macro?
Option Explicit
Sub Release_Combine_Text()
Dim rng As Range, r As Range, txt As String, Temp As Long
With Sheets("Release")
Set rng = Range("A117", Range("A" & Rows.Count).End(xlUp))
End With
For Each r In rng
txt = txt & r.Text
Next
With rng.Parent.Range("a11")
.Value = txt
For Each r In rng
With .Characters(Temp + 1, Len(r.Text)).Font
.FontStyle = r.Font.FontStyle
.Size = r.Font.Size
.Name = r.Font.Name
.Color = r.Font.Color
.Strikethrough = r.Font.Strikethrough
.Subscript = r.Font.Subscript
.Superscript = r.Font.Superscript
.Underline = r.Font.Underline
End With
Temp = Temp + Len(r.Text)
Next
End With
End Sub
Bookmarks