troubleshooting Question

VBA: Find and replace based on value of cell

Avatar of Michael Dobbins
Michael Dobbins asked on
VBAMicrosoft ExcelMicrosoft Office
1 Comment1 Solution37 ViewsLast Modified:
I am trying to find and replace data within a cell based on the value of a cell in a different column.

This is a 3 part update:

Step 1 - Look through column B for one of the agent IDs listed in the macro  (It would need to look for multiple values)
Step 2 - If there is a match to the listed Agent ID, replace the value in column L with X (this would also be stored in the macro as one value)
Step 3 - If there was a change made to column L, change the value in column A to "Y"

Hopefully this makes sense. It would then be stored to my personal macros. So when I export the user file for our phone system, I can make the changes and then upload it back into the phone system for quick updates to the agent skills.

I attached a sample file of what I export.

Here is the list of agent IDs (Column B) it will need to look for:


Here is the value that would need to replace the current data in column L:


I can do a basic find and replace macro but do not know how to make it based on the value of another cell.

Any help you can provide will be much appreciated!
Join our community to see this answer!
Unlock 1 Answer and 1 Comment.
Start Free Trial
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 1 Comment.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros