I want a VBA to look through a cell and determine whether the word XXX appears anywhere in it using the %. If yes I want VBA to change the entire cell to the word YYY.
Can anyone help me with this?
I want a VBA to look through a cell and determine whether the word XXX appears anywhere in it using the %. If yes I want VBA to change the entire cell to the word YYY.
Can anyone help me with this?
Copyright © 2021 Jogjafile Inc.
If you need to change only 1 cell's value, then use the InStr() function:
Obviously, replace
Cells(1, 1).Valuewith your cell reference.If you need to check multiple cells, then use the Range.Find method:
Again, replace
Worksheets(1).Range("a1:a500")with your own range reference.