
[已解決]批處理如何將字符串中的%替換為%%/單個百分號替換成雙百分號最后由 freesoft00 于 -11-28 18:49WSFFile=%SystemRoot%System32Wscript.exe %1 %*內(nèi)容如上,如果使用批處理生成一個res WSFFile=%%SystemRoot%%System32Wscript.exe %%1 %%*這樣的文件呢?字串替換我知道有例子:
我試驗了:set “a=WSFFile=%SystemRoot%System32Wscript.exe %1 %*”set temp=%a:^%=^%^%%不成功。謝謝!帖子沒有搜索,因為不知道這個問題應(yīng)該使用什么關(guān)鍵詞作為搜索。nclick="copycode($('code0'));">復(fù)制代碼
- @echo off
- set a=belcome to CMD borld!
- set temp=%a:b=w%
- echo %temp%
- pause

