Jump to content

Recommended Posts

Guest sanderd
Posted

Can I use wildcards in the StringReplace function?

If yes, how?

If not, isn't there any windows CLI program wich can?

I really need it...

Grtz

SanderD

Posted (edited)

you can use a commandline regular expressions program to do the replacements, or you can add in a delimiter and split it, replace, and remove the delimiters.

ex:

bob goes to the store

replace go* til a space

stringsplit by spaces would give you:

bob

goes

to

the

store

use stringleft to see if it has the first two characters as go, and if so, make your replacement, then reasemble.

I imagine you could make a UDF to do it, and I might try it later. One that would use *before and after perhapse. With stringinstr, stringreplace, and stringtrim, you have a lot of tools to design the one you want.

A regular expression editor would be the way to go for really good replacements, and that is how I do it when I have a lot of data i want to adjust.

Edited by scriptkitty

AutoIt3, the MACGYVER Pocket Knife for computers.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...