Edit/Replace using VBA in Excel

F

Froojam

Hi I'm a newbie and trying to implement some VBA code that automaticall
runs a the edit replace tool in a number of sheets. The problem I hav
is that I want the What:= & Replace:= values to refer to cells on a
index sheet (i.e not the activesheet).

Can anyone please help.

Thanks
 
B

Bernie Deitrick

Fully qualify the range object:

What:=ThisWorkbook.Worksheets("Index Sheet").Range("A3").Value
Replace:= ThisWorkbook.Worksheets("Index Sheet").Range("A4").Value

HTH,
Bernie
MS Excel MVP
 
Top