lol...Order pizza make an favorite beverage and use the IORRT code to put the echo and >>%file% in front and behind of Check.bat code Forgot why MasterDisaster used two echo in front of create %SystemDrive%\IR5.bat code but both place .bat file into Rearm folder or create .bat to put into Rearm folder So .bat creates .bat and places in certain place for task to run or .bat places reg/token codes to backup and restore
It's an easy code to test cause it will manifest in location then you look at code in .bat file and check if it got there Note: Code will put actual drive like C:\ instead of %systemdrive% code inside the (echo >>%file% stuff Example: IORRT.bat creation Code: SET file=%SystemDrive%\IORRT\IORRT.bat IF EXIST %file% attrib -h %file% echo @echo off >%file% echo net stop osppsvc >>%file% echo xcopy /cheriky "%SystemDrive%\IORRT\Backup\Files\Tokens" "%ALLUSERSPROFILE%\Microsoft\OfficeSoftwareProtectionPlatform" >>%file% echo REG DELETE HKLM\SOFTWARE\Microsoft\OfficeSoftwareProtectionPlatform /f >>%file% echo REG ADD HKLM\SOFTWARE\Microsoft\OfficeSoftwareProtectionPlatform /f >>%file% echo reg restore "HKLM\SOFTWARE\Microsoft\OfficeSoftwareProtectionPlatform" %SystemDrive%\IORRT\Backup\Registry\OfficeSPPInfo.hiv >>%file% echo net start osppsvc >>%file% echo IF Exist "%ProgramFiles%\Microsoft Office\Office15\OSPPREARM.exe" ( >>%file% echo "%ProgramFiles%\Microsoft Office\Office15\OSPPREARM.exe" >>%file% echo ) ELSE ( "%programfiles(x86)%\Microsoft Office\Office15\OSPPREARM.exe" >>%file% echo ) >>%file% echo schtasks /delete /tn "IORRT" /f >>%file% echo schtasks /create /tn "IORRT" /tr "%SystemDrive%\IORRT\IORRT.bat" /sc daily /mo 1 /ru "" >>%file% creates in %SystemDrive% Code: @echo off net stop osppsvc xcopy /cheriky "C:\IORRT\Backup\Files\Tokens" "C:\ProgramData\Microsoft\OfficeSoftwareProtectionPlatform" REG DELETE HKLM\SOFTWARE\Microsoft\OfficeSoftwareProtectionPlatform /f REG ADD HKLM\SOFTWARE\Microsoft\OfficeSoftwareProtectionPlatform /f reg restore "HKLM\SOFTWARE\Microsoft\OfficeSoftwareProtectionPlatform" C:\IORRT\Backup\Registry\OfficeSPPInfo.hiv net start osppsvc IF Exist "C:\Program Files\Microsoft Office\Office15\OSPPREARM.exe" ( "C:\Program Files\Microsoft Office\Office15\OSPPREARM.exe" ) ELSE ( "\Microsoft Office\Office15\OSPPREARM.exe" ) schtasks /delete /tn "IORRT" /f schtasks /create /tn "IORRT" /tr "C:\IORRT\IORRT.bat" /sc daily /mo 1 /ru ""
Or Code: SET file=%sd%\IR6.bat echo @echo off>>%file% echo echo Set objWMIService = GetObject("winmgmts:\\.\root\CIMV2") ^>^>drive.vbs>>%file% echo echo Set colItems = objWMIService.ExecQuery( "SELECT * FROM Win32_Volume",,48) ^>^>drive.vbs>>%file% echo echo For Each objItem in colItems ^>^>drive.vbs>>%file% echo echo If Hex(%sn%) = Hex(objItem.SerialNumber) then ^>^>drive.vbs>>%file% echo echo Wscript.Echo objItem.DriveLetter ^>^>drive.vbs>>%file% echo echo End If ^>^>drive.vbs>>%file% echo echo Next ^>^>drive.vbs>>%file% echo for /f %%%%A IN ('"cscript /nologo drive.vbs"') do set dl=%%%%A>>%file% echo set dl=%%dl:~0,-1%%>>%file% echo del drive.vbs>>%file% echo reg load HKLM\MY_SYSTEM "%%dl%%\Windows\System32\config\system" ^>NUL >>%file% echo reg delete HKLM\MY_SYSTEM\WPA /f ^>NUL >>%file% echo reg unload HKLM\MY_SYSTEM ^>NUL >>%file% echo echo cscript /b slmgr.vbs /ipk %PIDKEY% ^>%%dl%%\installkey.bat >>%file% echo echo slmgr.vbs /dlv ^>^>%%dl%%\installkey.bat >>%file% echo echo del "C:\installkey.bat" ^>^>%%dl%%\installkey.bat >>%file% echo echo CreateObject("WScript.Shell").Run """C:\installkey.bat""", 0, False ^>%%dl%%\key.vbs >>%file% echo echo @echo off ^>%%dl%%\launch.bat >>%file% echo echo wscript.exe "C:\key.vbs" ^>^>%%dl%%\launch.bat >>%file% echo echo del "%sd%\IR6.bat" ^>^>%%dl%%\launch.bat >>%file% echo echo del "C:\key.vbs" ^>^>%%dl%%\launch.bat >>%file% echo echo del "C:\launch.bat" ^>^>%%dl%%\launch.bat >>%file% echo reg load HKLM\MY_SOFTWARE "%%dl%%\Windows\System32\config\software" ^>NUL >>%file% echo reg add HKLM\MY_SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v InstallKey /t REG_SZ /d C:\launch.bat ^>NUL >>%file% echo reg unload HKLM\MY_SOFTWARE >>%file% echo wpeutil reboot >>%file% creates %sd%\IR6.bat %sd%=%SystemDrive% Code: @echo off echo Set objWMIService = GetObject("winmgmts:\\.\root\CIMV2") >>drive.vbs echo Set colItems = objWMIService.ExecQuery( "SELECT * FROM Win32_Volume",,48) >>drive.vbs echo For Each objItem in colItems >>drive.vbs echo If Hex() = Hex(objItem.SerialNumber) then >>drive.vbs echo Wscript.Echo objItem.DriveLetter >>drive.vbs echo End If >>drive.vbs echo Next >>drive.vbs for /f %%A IN ('"cscript /nologo drive.vbs"') do set dl=%%A set dl=%dl:~0,-1% del drive.vbs reg load HKLM\MY_SYSTEM "%dl%\Windows\System32\config\system" >NUL reg delete HKLM\MY_SYSTEM\WPA /f >NUL reg unload HKLM\MY_SYSTEM >NUL echo cscript /b slmgr.vbs /ipk >%dl%\installkey.bat echo slmgr.vbs /dlv >>%dl%\installkey.bat echo del "C:\installkey.bat" >>%dl%\installkey.bat echo CreateObject("WScript.Shell").Run """C:\installkey.bat""", 0, False >%dl%\key.vbs echo @echo off >%dl%\launch.bat echo wscript.exe "C:\key.vbs" >>%dl%\launch.bat echo del "\IR6.bat" >>%dl%\launch.bat echo del "C:\key.vbs" >>%dl%\launch.bat echo del "C:\launch.bat" >>%dl%\launch.bat reg load HKLM\MY_SOFTWARE "%dl%\Windows\System32\config\software" >NUL reg add HKLM\MY_SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /v InstallKey /t REG_SZ /d C:\launch.bat >NUL reg unload HKLM\MY_SOFTWARE wpeutil reboot in %SystemDrive% I remember MD left extra echo to ensure echo was left in manifested code
This is funny, the easy stuff your like but the hard stuff your like take it down We're like opposites from an alternative universe ...lol As been the whole development rearm concept cycle for me By the way will be going through all rearm concept archives tomorrow to place correct blame for who helped the most and tested to put in Rearm concept archives which you easily made it into although we're not friends yet ...lol
WELLLL, we could put in a bit of code that downloads a file for a user and once its found by the batch it could grab the magnet/torrent.
You mean like uTorrent ? If all these things helps in the learning process, then fine, but why is it too many things are being added and making way too complex.. I thought D420 is supposed to do just infinite re-arming of Win7 and Off2013 only ? Finding ISOs and downloading is user's responsibility if they want it, why do we need to spoon feed everything ? Just curious..
I think that would be too complex and if someone is not informed and gets error we'll explain they need torrent client like Bit Torrent which I recommend I like ideas, ideas are what created D420 but I think your right, we have done as nice an automated D420 as possible We'll just leave the possible error for now What we could do it this, instead of user getting error we could simply give message they have to install Bit Torrent and try again The message can stay for a few seconds then disappear with ping like the other ping code
Was playing around with writing Check.bat to disc...but it´s really annoying, as you cannot use variables and sometimes escapes don´t seem to work properly. So maybe you should opt for shipping Duality with a Check.bat, which is copied to the proper folder if needed. (Btw, my inbox is empty now )
Need to figure out if its possible to do something that will echo out an entire section with one output line, don't know if its possible. Not sure if it will be a work around escaping or if even possible echo ( line 1 line 2 line 3 ) >>file.txt
Should look like: Code: >Check.bat ( echo line 1 echo line 2 ... echo line n ) This will still need to use static values instead of variables. EDIT: and for "|" and ">" you´ll still need escapes to prevent direct processing.
Actually we just needed the msgbox to give yes or no at end of 180 day trial I think we should use just console message and ping to close concole We could do that but I'm sure it can be put in D420, just have to let the idea surface Sent pm Thanks you guys