Sub CopyRange()
Application.ScreenUpdating = False
Dim LastRow As Long, ws As Worksheet, desWS As Worksheet, x As Long: x = 6
Set desWS = Workbooks("[COLOR="#FF0000"]WorkbookB.xlsx[/COLOR]").Sheets("[COLOR="#FF0000"]Sheet1[/COLOR]")
For Each ws In Sheets
LastRow = desWS.Range("A" & desWS.Rows.Count).End(xlUp).Row
If LastRow < 5 Then
desWS.Range("A5") = ws.Name
ws.Range("A20:Z30").Copy desWS.Range("A6")
Else
With desWS
.Cells(.Rows.Count, "A").End(xlUp).Offset(3, 0) = ws.Name
ws.Range("A20:Z30").Copy .Cells(.Rows.Count, "A").End(xlUp).Offset(1, 0)
End With
End If
Next ws
Application.ScreenUpdating = True
End Sub