Manipulate a string to use later
Hi,
I was hoping for some guidance. I would like to create a script file that pull in a string - manipulates that string to be used by another file.
Example: Pull in the %computername% then change the string based on a pattern - every other character has say $ between them and the last letter is capital.
So if the computer name is myPCname - pull in that string - and change it to my$PC$na$mE and then save that result to a variable that can be access by another cmd file.
Any ideas are appreciated - thanks
0 Comments
[ + ] Show comments
Answers (2)
Please log in to answer
Posted by:
anonymous_9363
5 years ago
Sometimes, people simply invite being sent LMGTFY links...
Comments:
-
i am a believer is multiple fronts,so i ask the question while doing my own research - I have been pointed in a better direction that way.
if you have some thoughts on sites for resources i welcome your input, otherwise you comments is as much a waste of time as you feel my question is. - jg1155 5 years ago-
You could have got the answer to your question in an order of magnitude less time than it took to type it out.
>if you have some thoughts on sites for resources
Ummm...what would be the point, since you "have been pointed in a better direction"? - anonymous_9363 5 years ago
Posted by:
chucksteel
5 years ago
Options off the top of my head:
- Set an environment variable
- Write the string to a file and read that file with the other script
Comments:
-
Thanks you - i have actually been working on a a simualar solution - just last night - appricated you assistance. - jg1155 5 years ago