I am looking to replace the contents of selected cells in column E with a formula with in a macro. For each cell in column E sheet1 that equals "Not Assigned" I want the macro to replace it with the following formula =iferror(vlookup(cell.offset(, -4),'sheet2'A:C,3,false),"Not Assigned"). The file typically has 25k-30k rows, cell.offset(, -4) needs to be dynamic so the formula is looking a the cell in column A of the row that it finds a "Not Assigned" in column E.

thanks, s4