|
回复 #29 fujianabc 的帖子
不是,菜单是自己用以下命令加的,不知道有没有问题?
@ECHO OFF
@CD /D "%~DP0"
IF NOT EXIST "C:\BOOTMGR" @ATTRIB -R -A -S -H "%~DP0BOOTMGR"
IF NOT EXIST "C:\BOOTMGR" @COPY /Y /V "%~DP0BOOTMGR" "C:\" >NUL
IF EXIST @ATTRIB +R +A +S +H "C:\BOOTMGR"
IF NOT EXIST "C:\BOOT\" @MD "C:\BOOT\"
IF EXIST "C:\BOOT\" @ATTRIB +R +A +S +H "C:\BOOT"
IF EXIST "C:\BOOT\BCD" @COPY /Y /V "C:\BOOT\BCD" "C:\BOOT\BCD_BAK" >NUL
IF EXIST "C:\BOOT\BCD" @DEL /F /A /Q "\\?\C:\BOOT\BCD" >NUL
BOOTSECT.EXE /NT60 "C:" /FORCE /MBR
BCDEDIT /CREATESTORE "C:\BOOT\BCD"
BCDEDIT /STORE "C:\BOOT\BCD" /CREATE {BOOTMGR} /D "Windows Boot Manager"
BCDEDIT /STORE "C:\BOOT\BCD" /SET {BOOTMGR} LOCALE "zh-CN" >NUL
BCDEDIT /STORE "C:\BOOT\BCD" /SET {BOOTMGR} INHERIT {BOOTLOADERSETTINGS} >NUL
BCDEDIT /STORE "C:\BOOT\BCD" /CREATE {NTLDR} /D "Microsoft Windows XP Professional"
BCDEDIT /STORE "C:\BOOT\BCD" /SET {NTLDR} DEVICE PARTITION="C:"
BCDEDIT /STORE "C:\BOOT\BCD" /SET {NTLDR} PATH "\NTLDR"
BCDEDIT /STORE "C:\BOOT\BCD" /DISPLAYORDER {NTLDR} /ADDLAST
BCDEDIT /STORE "C:\BOOT\BCD" /DEFAULT {NTLDR}
BCDEDIT /STORE "C:\BOOT\BCD" /SET {BOOTMGR} TIMEOUT "9"
PAUSE
SET VID=
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /CREATE /D "%~DP0WIN7.VHD" /APPLICATION OSLOADER >"%TEMP%\VID.TXT"
FOR,/F,"TOKENS=2 DELIMS={",%%I,IN (%TEMP%\VID.TXT) DO (SET VIDA=%%I)
FOR,/F,"TOKENS=1 DELIMS=}",%%I,IN ("%VIDA%") DO (SET VID={%%I})
ECHO %VID%>"%TEMP%\VID.TXT"
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /SET %VID% DEVICE VHD="[%~D0]%~P0WIN7.VHD" >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /SET %VID% PATH "\WINDOWS\SYSTEM32\WINLOAD.EXE" >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /SET %VID% LOCALE "zh-CN" >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /SET %VID% INHERIT {BOOTLOADERSETTINGS} >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /SET %VID% SYSTEMROOT "\WINDOWS" >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /SET %VID% OSDEVICE VHD="[%~D0]%~P0WIN7.VHD" >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /SET %VID% DETECTHAL ON >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /DISPLAYORDER %VID% /ADDLAST >NUL
BCDEDIT.EXE /STORE "C:\BOOT\BCD" /TIMEOUT 9 >NUL
@DEL /F /A /Q "%TEMP%\VID.TXT" >NUL
PAUSE |
|