I have done some searching and found a similar question with some helpful code.
Excel Macro - Select all cells with data and format as table
The code given is
Sub A_SelectCellsWithData()
Range("A1").Select
Range(Selection, ActiveCell.SpecialCells(xlLastCell)).Select
End Sub
However, this also selects blank rows in between the whole sheet of data.
What I need is to only select the cells with data.
i.e. In addition to the above code, omit all blank rows when selecting cells in a sheet with data.
I really can't find a solution to this question after such a long time searching online. Thank you guys!