
[已解決]批處理call命令很懵的錯誤命令行不正確最后由 淺暮丶千殤 于 -11-7 02:52
- @echo off
- SETLOCAL ENABLEDELAYEDEXPANSION
- set file=C:UsersAdministratorDesktopcheatengine-x86_64.po
- set file1=D:Program FilesCheat Enginelanguageszh_CNcheatengine-x86_64.po
- set count=0
- set str=
- for /F tokens=1* delims=: %%a in ('findstr /N /C:#: %file1%') do (
- Call :GetfileStr %%b %file%
- pause
- )
- pause
- Exit
- :GetfileStr
- echo.1
- pause
- for /F tokens=1* delims=: %%a in ('findstr /N /C:%~1 %~2') do (
- set count=%%a
- Call :GetMsgstr !count!
- )
- Goto :Eof
- :GetMsgstr
- for /F tokens=1* skip=%count% delims= %%a in (%file%) do (
- if %%a equ msgctxt Set /A count+=2
- if %%a equ msgid (if %%b equ Goto :Eof) && Set /A count+=1
- if %%a equ msgstr (
- if %%b equ Goto :Eof
- echo.%%b
- set str=%%b
- REM Call :GetfileStr %%b %file% 這個語句放在這里會報錯: 命令行不正確, 但是放在其他地方則是正常的, 真的很懵
- Call :GetfileStr %%b %file%
- Goto :Eof
- )
- Goto :GetMsgstr
- )
nclick="copycode($('code0'));">復制代碼