Hi I'm trying to find the max value for each column with this code, but it stops after a blank row. I want the code to find the max of the entire column even if there are blank rows in the data. Any idea how to fix this code? Or is there a better way to write the code? Thanks!
'Outputting max value for each column
![]()
Sub Max_Columns() With Range("A2").CurrentRegion Range("A1").Resize(, .Columns.Count).FormulaR1C1 = "=MAX(R[2]C:R[" & .Rows.Count & "]C)" End With 'Paste values Rows(1).EntireRow.Copy Rows(1).PasteSpecial xlPasteValues End Sub
Bookmarks