I was wondering if I can use the Invoke Code to change the format of the cells in my Excel file. (Fonts, Bold, Border, etc)
Dim ws As Worksheet: Set ws = ThisWorkbook.ActiveSheet
Dim lastRow As Long
lastRow = Cells(Rows.Count, 4).End(xlUp).Row
With ws.Range(ws.Cells(lastRow, 4), ws.Cells(lastRow, 10))
.Font.Bold = True
.Borders.LineStyle = xlContinuous
This is the code that I want to use. Is there any way to incorporate that in there?