回复 8# jzy8158 - @echo off
- set n=0
- setlocal enabledelayedexpansion
- (for /f "delims=" %%i in (a.hex) do (
- if "%%i"==":02000004800971" set n=1
- if !n!==0 (
- echo,%%i
- ) else (
- set "str!n!=%%i"
- set /a n+=1
- if !n!==9 set n=0
- )
- ))>B.hex
- (for /l %%a in (1,1,8) do echo,!str%%a!
- echo,:00000001FF
- )>new-A.hex
- pause
复制代码 刚才有点小问题,已修改。 |