Problem: I have multiple sheets which contain varying number of rows and columns which contain numeric data. Value of my interest from each table is is last cell (last row and last column) highlighted in excel irrespective of table size. I Need to copy this last cell value from each long data sheets onto sheet 1 as shown against respective sheet numbers.
I have tried below VBA code
The problem with this code is I need to repeat this for every sheet. so please suggest/guide so that i don't have to rerun the same code for each sheet separately.
I have tried below VBA code
Code:
Dim lRow As Integer
Dim lCol As Long
lRow = Cells.Find(What:="*", _
After:=Range("A1"), _
LookAt:=xlPart, _
LookIn:=xlFormulas, _
SearchOrder:=xlByRows, _
SearchDirection:=xlPrevious, _
MatchCase:=False).Value
Range("BD71").Copy Worksheets("Sheet1").Range("F5")
The problem with this code is I need to repeat this for every sheet. so please suggest/guide so that i don't have to rerun the same code for each sheet separately.
Attachments
Last edited by a moderator: