batman 当前离线
考官
荣誉版主
liushenchi 当前离线
列兵
TOP
lance_man 当前离线
apang 当前离线
上将
@echo off for /f "delims=" %%a in (a.txt) do ( set "var=%%a" call :lp %%var:--^>= %% ) pause :lp for /l %%b in (1 1 34) do shift if "%1"=="株洲县区域营销中心" (echo %2) else echo %3复制代码
评分人数
@echo off for /f "delims=" %%a in (a.txt) do ( set "var=%%a" call :lp %%var:--^>= %% ) pause :lp if "%4"=="株洲县区域营销中心" (echo %5) else echo %6复制代码
@echo off&setlocal enabledelayedexpansion for /f "delims=" %%a in (a.txt) do ( set "str=%%a"&set "str=!str:-->= !"&set /a n=0 for %%a in (!str!) do ( if defined flag echo %%a&set "flag="&set /a n+=1 set /a n+=1 if !n! equ 4 if "%%a" equ "株洲县区域营销中心" set "flag=a" if !n! equ 5 set "flag=a" ) ) pause>nul复制代码
qzwqzw (活着就是幸福)当前离线
贵宾
冷玉公子 当前离线
三级士官
@Echo Off Set "Ad=株洲县农村营销中心" For /F "tokens=1-30 delims=-->" %%1 In (Log.txt) Do ( If "%%4"=="%Ad%" ( Echo 找到字符:%Ad% 输出: %%5 )Else ( Echo 未找到字符:%Ad% 输出: %%6 ) ) Pause>Nul复制代码
@echo off for /f "tokens=4,5,6 delims=-->" %%a in (a.txt) do ( if "%%a"=="株洲县区域营销中心" (echo %%b) else echo %%c ) pause复制代码