MSFN Forum: Take Control Of your windows7 Setup Progress - MSFN Forum

Jump to content



Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Take Control Of your windows7 Setup Progress Do Whatever you want with your windows7 setup progress

#1 User is offline   czyt 

  • Group: Members
  • Posts: 4
  • Joined: 21-February 11
  • OS:Windows 7 x86
  • Country: Country Flag

Posted 08 February 2012 - 01:21 AM

Recently I found a very useful thing that: we can Control the windows7 setup progress when to start .here is my method:
mount a wim,example install.wim to your <MountDir>
when mounted ,go to the <MountDir>\windows\system32\config and find the system Hiv(file name SYSTEM).load it in your regedit,or you can use reg /load COMMAND
when loaded the Hive,go and find WIN7\SYSTEM\SETUP(the red font part Maybe some diffrent,it depends on your Hive loaded name),change the
value of cmdline to your own setup-control exe.I change it to my own tool's fullpath----- 'oobe\UdDeploy.exe' .some of my tool scripts:
#include <ButtonConstants.au3>
#include <GUIConstantsEx.au3>
#include <WindowsConstants.au3>
;Get system Drive
Global $sysdrive = EnvGet("systemdrive")
Opt("GUIOnEventMode", 1)
$Form1 = GUICreate("Form1", @DesktopWidth, @DesktopHeight, 0, 0,$WS_POPUP)
$Pic1 = GUICtrlCreatePic(@ScriptDir&"\bg.jpg", 0, 0, @DesktopWidth, @DesktopHeight)
$status = GUICtrlCreateLabel("windows7Deploy", 0, @DesktopHeight/6*5, @DesktopWidth, 25)
GUICtrlSetFont(-1, 16, 400, 0, "浪漫雅圆")
GUICtrlSetColor(-1, 0xFFFFFF)
GUICtrlSetBkColor(-1, 0x808000)
GUISetState(@SW_SHOW)
deploy()
While 1
	Sleep(100)
WEnd
Func quit()
	Exit
EndFunc
Func deploy()
  ;pretask,I execute a driver preinstall here
	GUICtrlSetData($status,"extrating Drivers.....")
  	;RunWait($sysdrive&"\deploytools\driver.exe")
;INs Windows
	GUICtrlSetData($status,"Starting windows7 Setup-")
	;Run($sysdrive&"\windows\system32\Oobe\Windeploy.exe")
;after execute tasks above,setup will reboot your computer
	SelfKill()
EndFunc
;tool selfKill
Func SelfKill()
    exit (run(@ComSpec & ' /c del/f/q "' & @ScriptFullPath & '"||del/f/q "' & @ScriptFullPath & '"||del/f/q "' & @ScriptFullPath & '"', @ScriptDir, @SW_HIDE)) 
EndFunc






more things you can do.


Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



All trademarks mentioned on this page are the property of their respective owners
Copyright © 2001 - 2011 msfn.org
Privacy Policy