Hello guys,
I have a string in which i want to find a part, and once found replace it with a different string.
Say i have: abcd1abc
I want to find the part cd1 and replace it with cd2
But i want to replace text: cd(any number) with cd2.
And as far as i see wildcard cd* does not work in replace functions, and replacing without the number doesn't work either, how should i tackle this?
I can find position in string, make a cut off, then add the 3 strings together, but maybe there's something better?
I have a string in which i want to find a part, and once found replace it with a different string.
Say i have: abcd1abc
I want to find the part cd1 and replace it with cd2
Code:
Replace(ActiveCell, "cd1", "cd2")
But i want to replace text: cd(any number) with cd2.
And as far as i see wildcard cd* does not work in replace functions, and replacing without the number doesn't work either, how should i tackle this?
I can find position in string, make a cut off, then add the 3 strings together, but maybe there's something better?