Forums before death by AOL, social media and spammers... "We can't have nice things"
|    alt.msdos.batch.nt    |    Fun with Windows NT batch files    |    68,980 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 68,798 of 68,980    |
|    Zaidy036 to Anton Shepelev    |
|    Re: Replacing a character with a percent    |
|    22 May 24 10:19:20    |
      From: Zaidy036@air.isp.spam              On 5/21/2024 12:58 PM, Anton Shepelev wrote:       > Hello, all.       >       > How can one replace `#' with `%' in the value of a variable?       > I have tried:       >       > SET VAR=%VAR:#=%%%       > SET VAR=%VAR:#=^%%       >       > but to no avail.       >       why not generate a new variable name using text commands something like:              Find location of # = n       Set xx=%VAR:~,n%       Set yy=%VAR:~n,%       Set VAR=%xx%%%yy%              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca