无忧启动论坛

标题: 请教批处理高手帮忙看下!!! [打印本页]

作者: zbmno1    时间: 2008-4-6 01:28
标题: 请教批处理高手帮忙看下!!!
这是我修改过的批处理
CLS
@ECHO OFF
TITLE Drivers-from-CD Installation
color 1F
::  Set Current Drive as CD
CD /D "%~dp0"
::  Set Drivers Location Folder
SET DRV=Drivers
::  Ticker script
ECHO.exec hide %CD%\Process.exe -r setup.exe >%SystemDrive%\Ticker.ncl
ECHO.wait 10000 >>%SystemDrive%\Ticker.ncl
ECHO.exec hide %CD%\Process.exe -p SetupCopyOEMInf.exe high >>%SystemDrive%\Ticker.ncl
ECHO.exec hide %CD%\Process.exe -s setup.exe >>%SystemDrive%\Ticker.ncl
ECHO.wait 50000 >>%SystemDrive%\Ticker.ncl
ECHO.script %SystemDrive%\Ticker.ncl >>%SystemDrive%\Ticker.ncl
::  Pre-Install (Suspend Setup, and Set Setup to Low Priority)
.\Process.exe -s setup.exe
.\Process.exe -p setup.exe low
::  Allow for Unsigned Drivers
START .\WatchDriverSigningPolicy.exe
::  If Compressed Drivers Exist, Unzip Them & Change Drivers Location Folder to Hard Drive
IF EXIST Drivers.exe (
SET DRV=%SystemDrive%\Drivers
%systemroot%\system32\Drivers.exe
)
::  Run NirCmd Ticker Script (code above)
START .\NirCmd.exe script %SystemDrive%\Ticker.ncl
::  Install Drivers
.\SetupCopyOEMInf.exe "%DRV%"
::  Post-Install (Close NirCmd, Setup Priority back to Normal, Resume Setup)
.\Process.exe -k NirCmd.exe
.\Process.exe -p setup.exe normal
.\Process.exe -r setup.exe
::  Delete Ticker File
DEL %SystemDrive%\Ticker.ncl
EXIT
Driver.exe一直运行,无法关闭
---------------------------------------------
CLS
@ECHO OFF
TITLE Drivers-from-CD Installation
color 1F
::  Set Current Drive as CD
CD /D "%~dp0"
::  Set Drivers Location Folder
SET DRV=Drivers
::  Ticker script
ECHO.exec hide %CD%\Process.exe -r setup.exe >%SystemDrive%\Ticker.ncl
ECHO.wait 10000 >>%SystemDrive%\Ticker.ncl
ECHO.exec hide %CD%\Process.exe -p SetupCopyOEMInf.exe high >>%SystemDrive%\Ticker.ncl
ECHO.exec hide %CD%\Process.exe -s setup.exe >>%SystemDrive%\Ticker.ncl
ECHO.wait 50000 >>%SystemDrive%\Ticker.ncl
ECHO.script %SystemDrive%\Ticker.ncl >>%SystemDrive%\Ticker.ncl
::  Pre-Install (Suspend Setup, and Set Setup to Low Priority)
.\Process.exe -s setup.exe
.\Process.exe -p setup.exe low
::  Allow for Unsigned Drivers
START .\WatchDriverSigningPolicy.exe
::  If Compressed Drivers Exist, Unzip Them & Change Drivers Location Folder to Hard Drive
IF EXIST Drivers.7z (
SET DRV=%SystemDrive%\Drivers
.\7za.exe x -y -aoa -o"%SystemDrive%\Drivers" ".\Drivers.7z"
)
::  Run NirCmd Ticker Script (code above)
START .\NirCmd.exe script %SystemDrive%\Ticker.ncl
::  Install Drivers
.\SetupCopyOEMInf.exe "%DRV%"
::  Post-Install (Close NirCmd, Setup Priority back to Normal, Resume Setup)
.\Process.exe -k NirCmd.exe
.\Process.exe -p setup.exe normal
.\Process.exe -r setup.exe
::  Delete Ticker File
DEL %SystemDrive%\Ticker.ncl
EXIT
这是原批处理




欢迎光临 无忧启动论坛 (http://wuyou.net./) Powered by Discuz! X3.3