I tried it, and it doesn't work as needed: I need it to match the case of the last letter. So if I want to replace "FOOBAR" with "whatever", it will return "WHATEVer" instead of "WHATEVER".
Newever versions of the Regexp FAQ have some routines not online here that do that fiddling with bits in ASCII. Not necessarily Unicode compliant but neat tricks nontheless.
In reply to Re: Re: Case-preserving regexp search and replace?
by rrwo
in thread Case-preserving regexp search and replace?
by rrwo
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |