Jonno said:
Thanks Tom. Your code does do want I need regarding matching the row heights, but I'd like to be able to select the 'from' and 'to' rows.
This would do that for a single "copy" row...after that the code gets even kludgier than this, which is already getting messy. With this you can copy one row's height to a single row or optional range of rows. The default of the From row is the active row but you can change it in the input box to any row.
Sub Test1()
Dim FromRow As String, StartRow As String, EndRow As String
FromRow = InputBox("Enter the row whose height you want to copy.", "Paste height of what row?", ActiveCell.Row)
If IsNumeric(FromRow) = False Then Exit Sub
If Int(FromRow) < 1 Or Int(FromRow) > 65536 Then Exit Sub
StartRow = InputBox("What is the first row in a range where" & vbCrLf & "you want to copy the height of row " & FromRow & "?", "Start from where?")
If IsNumeric(StartRow) = False Then Exit Sub
If Int(StartRow) < 1 Or Int(StartRow) > 65536 Then Exit Sub
EndRow = InputBox("What is the last row in a range where" & vbCrLf & "you want to copy the height of row " & FromRow & "?", "OPTIONAL - Ending where?")
If IsNumeric(EndRow) = False And Len(EndRow) <> 0 Then Exit Sub
If EndRow <> "" Then
If Int(EndRow) > 0 Or Int(EndRow) <= 65536 Then
Range(StartRow & ":" & EndRow).RowHeight = Rows(FromRow).RowHeight
End If
Else
Rows(StartRow).RowHeight = Rows(FromRow).RowHeight
End If
End Sub
And yes, Application.InputBox is an alternative but the method posted above allows for not worrying about the user creating an error by not entering a column row range separator, or inconveniencing the user to scroll down 60,000 rows to select a certain obscure destination row number.