Hello,
Your help much appreciated here. I completely stuck (have been for days).
I have some code below with
1) find the last cell in a columnwith data and (2) Attempts having specified the beginning of a range, tries to change the whole range red.
Am gutted, cant do it! Any help mcuh appreciated, here is the code:
Sub Trial()
Dim LastRow As Long
Dim LastCol As Integer
Dim myRange As Range
Workbooks.Open ("C:\Report.xls")
'Find the LAST real row
LastRow = ActiveSheet.Cells.Find(What:="*", _
SearchDirection:=xlPrevious, _
SearchOrder:=xlByRows).Row
' Find the LAST real column
LastCol = ActiveSheet.Cells.Find(What:="*", _
SearchDirection:=xlPrevious, _
SearchOrder:=xlByColumns).Column
ActiveWorkbook.Activate
ActiveSheet.Range(Cells(11, 17), _
Cells(LastRow, LastCol)).Interior.Color = vbRed
End Sub
Your help much appreciated here. I completely stuck (have been for days).
I have some code below with
Am gutted, cant do it! Any help mcuh appreciated, here is the code:
Sub Trial()
Dim LastRow As Long
Dim LastCol As Integer
Dim myRange As Range
Workbooks.Open ("C:\Report.xls")
'Find the LAST real row
LastRow = ActiveSheet.Cells.Find(What:="*", _
SearchDirection:=xlPrevious, _
SearchOrder:=xlByRows).Row
' Find the LAST real column
LastCol = ActiveSheet.Cells.Find(What:="*", _
SearchDirection:=xlPrevious, _
SearchOrder:=xlByColumns).Column
ActiveWorkbook.Activate
ActiveSheet.Range(Cells(11, 17), _
Cells(LastRow, LastCol)).Interior.Color = vbRed
End Sub