• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

How to get .Replace to recognize UPPER case?

Eloise T

Active Member
I have a VBA macro using .Replace that looks for variations of "Canceled" and replaces the variation with (you guessed it) "Canceled"
It converts: cancelled, CANCELLED, canceled, BUT not CANCELED... it leaves it as CANCELED.
How do you get .Replace to check for correctly spelled UPPER CASE CANCELED and change it to Canceled?
I tried changing xlWhole to xlPart with no effect.
Thanks in advance for your assistance.

.Replace "cancelled", "Canceled", xlWhole
.Replace "CANCELED", "Canceled", xlWhole
 
Back
Top