|
|
本帖最后由 sunzhiguolu 于 2012-6-10 17:35 编辑
- @echo off
- echo FileA has be created. > A.txt
- echo FileB has be created. > B.txt
- if not exist CombineResult.ini call :PreFile CombineResult.ini
- :ExecCommand
- ::--------------------------------------------------------
- ::insert Alert Test command exec state.
- ::pause
- ::--------------------------------------------------------
- copy a.txt + b.txt CombineResult.ini
- echo.
- type CombineResult.ini
- ::不知为何if,else分支处的语句不能被执行!!!
- if %errorlevel%==1 (echo command execcute error
- pause) else(
- echo Clean System Resourse...
- call :CleanSystemResources A.txt
- call :CleanSystemResources B.txt
- call :CleanSystemResources CombineResult.ini)
- pause > nul
- :PreFile
- ::must add '.' char with echo command.
- echo. > %1
- goto ExecCommand
- :CleanSystemResources
- if exist %1
- del %1
- ::echo %1
复制代码 希望大家给与指点... |
|