E
Ed
I'm iterating down a column of cells on Sheet1. If the cell is blank, I
want to insert the following formula:
ActiveCell.Formula = "=IF(ISERROR(MATCH($C" & j &
"TIRs!$C$2:$C$15000,0)),0,INDEX(TIRs!" & i & "$2:" & i & "$15000,MATCH($C" &
j & "TIRs!$C$2:$C$15000,0)))"
where i and j are the column and row indexes (Dimmed as Long) for the
ActiveCell. The variables do have the values. But I get the following:
Application-defined or object-defined error.
What I'm trying to do is pick up some data I lost from a previous version of
this workbook. If the cell is blank, there may be a value that is supposed
to be there on the previous version; look at Column C for that same row and,
if that value matches the value in Col C on Sheet(TIRs), pull the value onto
Sheet1.
I use the formula in my weekly updates and it works there - *BUT* I use it
without variables - it's inserted in row2 of the column and run down. I
can't do that here because the older version of the data that has the lost
data does not have new data I've inserted before I discovered the problem.
So I'm trying to insert this modified formula into only blank cells so it
picks up the ActiveCell row and column.
Any help is appreciated.
Ed
want to insert the following formula:
ActiveCell.Formula = "=IF(ISERROR(MATCH($C" & j &
"TIRs!$C$2:$C$15000,0)),0,INDEX(TIRs!" & i & "$2:" & i & "$15000,MATCH($C" &
j & "TIRs!$C$2:$C$15000,0)))"
where i and j are the column and row indexes (Dimmed as Long) for the
ActiveCell. The variables do have the values. But I get the following:
Application-defined or object-defined error.
What I'm trying to do is pick up some data I lost from a previous version of
this workbook. If the cell is blank, there may be a value that is supposed
to be there on the previous version; look at Column C for that same row and,
if that value matches the value in Col C on Sheet(TIRs), pull the value onto
Sheet1.
I use the formula in my weekly updates and it works there - *BUT* I use it
without variables - it's inserted in row2 of the column and run down. I
can't do that here because the older version of the data that has the lost
data does not have new data I've inserted before I discovered the problem.
So I'm trying to insert this modified formula into only blank cells so it
picks up the ActiveCell row and column.
Any help is appreciated.
Ed