Consulting

Results 1 to 2 of 2

Thread: Find and replace macro bugging out with finding #VALUE!

  1. #1
    VBAX Tutor
    Joined
    Jan 2006
    Posts
    248
    Location

    Find and replace macro bugging out with finding #VALUE!

    I have a find and replace macro in the attached work book that works fine except for when it has to find and replace the following #VALUE!
    it bugs out on this line
     myRange.Replace What:=cel.Value, Replacement:=cel.Offset(0, 1).Value
    I have a find and replace formula that works fine as a comparison on the formula test page.

    Even if there is nothing to replace on the Main Sheet the fact that #VALUE! is on the replace page caused the macro to bug out at the above line.

    Any thoughts why this is happening would be appriciated.

    Thanks
    Attached Files Attached Files

  2. #2
    VBAX Tutor
    Joined
    Jan 2006
    Posts
    248
    Location
    Well after more testing I have it working now, I had #VALUE! on the replace sheet when I added #value! as lower case it had no problem and now works fine.

    So I am marking this as solved.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •