|
-
Mar 25th, 2020, 03:19 AM
#1
Thread Starter
New Member
Skip a String from Replace, if it has any suffix or postfix <VBScript>
I have a one Big File, In which I need to replace one string from the another.
File is getting Generated from the Jenkins Build and to process that, its using VBscript.
Here is the Deal for me, I can simply replace the string like this,
Replace(str_Renamed, "Variables", "Variables_Base", 1, -1, 1)
but in the same file "variables" is also there with suffix and postfix, these particular string i need to skip from the replace.
does VBscript has any function which can be useful for above conditions.
I am also looking for the answers, If I would find anything for it. I will post here.
-
Mar 25th, 2020, 09:24 AM
#2
Re: Skip a String from Replace, if it has any suffix or postfix <VBScript>
Are there other characters next to "Variables" when it is without the postfix/suffix, i.e. could you use a space or space characters to isolate the match.
e.g.
Replace(str_Renamed, " Variables ", " Variables_Base ", 1, -1, 1)
"Anyone can do any amount of work, provided it isn't the work he is supposed to be doing at that moment" Robert Benchley, 1930
-
Mar 25th, 2020, 10:44 PM
#3
Thread Starter
New Member
Re: Skip a String from Replace, if it has any suffix or postfix <VBScript>
Thanks for the Reply, i did try the same way as you are suggesting but its not working.
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|