Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Sub FindReplaceAll()
- 'PURPOSE: Find & Replace text/values throughout entire workbook
- Dim sht As Worksheet
- Dim fnd As Variant
- Dim rplc As Variant
- Dim p As Integer
- Dim q As Integer
- p = 3
- q = p + 1
- fnd = "$3"
- rplc = "$" & q
- For Each sht In ActiveWorkbook.Worksheets
- sht.Cells.Replace what:=fnd, Replacement:=rplc, _
- LookAt:=xlPart, SearchOrder:=xlByRows, MatchCase:=False, _
- SearchFormat:=False, ReplaceFormat:=False
- Next sht
- p=q
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement