Hi
It’s been a while, but I was helped previously with this to highlight last cell in column A…it works fine, but can’t figure what to add to it to make it run automatically when the spreadsheet is opened.
Thanks
Sub LASTCELL()
theDoc = ThisComponent
theSheet = theDoc.Sheets(0)
eCells = theSheet.Columns(0).QueryEmptyCells
finRg = eCells(eCells.Count - 1)
If finRg.RangeAddress.EndRow<>theSheet.RangeAddress.endRow Then Exit Sub
target = finRg.GetCellByPosition(0, 0)
theDoc.CurrentController.Select(target)
End Sub