Jump to content

Using "after desktop loads" with WPI not at root


Recommended Posts

I was previously using an older method (before the .exe was released) of running wpi.hta during the first boot, but it was interfering with my driverpacks finisher. I have a "wpi" folder at the root of my dvd, with all the wpi stuff inside it to keep it all clean. Here is my old modified .cmd:

for /f "delims=: tokens=1" %%i in ("%~dp0") do set drive=%%i:
set wpipath=%drive%\wpi

SET KEY=HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnceEx

REG ADD %KEY%\999 /V 1 /D "%wpipath%\WPI.hta" /f

How do I go about modifying the new .inf to point to the correct file? I am not sure about the language that I can use in this .inf file

[Version]
Signature="$CHICAGO$"

[DefaultInstall]
AddReg=Run.AddReg

[Run.AddReg]
HKLM,"%RUN%","%WPI%",,"RunDll32 advpack.dll,LaunchINFSection ""%01%\%INF%"",Execute"

[Execute]
RunPreSetupCommands=Launch.WPI:1
DelReg =Run.DelReg

[Launch.WPI]
CMD /Q /C CD /D """%01%\..\WPI""" & START /WAIT /B WPI.hta

[Run.DelReg]
HKLM,"%RUN%","%WPI%"

[Strings]
RUN="SOFTWARE\Microsoft\Windows\CurrentVersion\RUN"
WPI="Windows Post Install"
INF="RunWPI.inf"

Thanks in advance!

Edited by gospeed
Link to comment
Share on other sites


just added the folder name and retested...

[Launch.WPI]
CMD /Q /C CD /D """%01%\..\WPI\WPI.hta""" & START /WAIT /B WPI.hta

still "cannot find wpi.hta"

I assume I need to pint it to the cd drive? If I go to the run command and type e:\wpi\wpi.hta it will open, but you never know what the drive letter will be. Do I need to incorporate some of the text from before to define the location of wpi?

Edited by gospeed
Link to comment
Share on other sites

Oh you actually have it like my pic shows in the example?

Then you need no changes.

[Launch.WPI]
CMD /Q /C CD /D """%01%\..\WPI""" & START /WAIT /B WPI.hta

Is assuming you have the run_wpi.inf in the oem folder and the wpi folder at the root of the disk.

%01%\..\ = the root of the disk and then you have the WPI for the folder and then wpi.hta for the prog

If you need a further explanation or if there is an error you will have to wait like 12 hours for ricktendo to come online he is the one that designed the inf....

Link to comment
Share on other sites

yeah, I have the $oem$ folder structure just "as-downloaded" which is basically how it was in my old version as well (except using a .cmd instead of the .inf). My WPI Folder sits at the very root of the dvd.

I assume I should be able to open the run command and type in:

CMD /Q /C CD /D """%01%\..\WPI""" & START /WAIT /B WPI.hta

When i do, it cannot find wpi.hta

but, if i change to the actual drive letter:

CMD /Q /C CD /D """E:\WPI""" & START /WAIT /B WPI.hta

It opens normally.

For some reason, I cant use the %01%\.. command :blink:

Thank you for your help, and HAPPY BIRTHDAY :thumbup

Edited by gospeed
Link to comment
Share on other sites

I have searched and searched, I cannot find any documentation on the command "%01%\..", and if I replace it with the corect driveletter, the command works. Is there another way for this command to define where wpi exists?

Link to comment
Share on other sites

That code is not meant for CMD files... Its INF only

01 SourceDrive:\pathname (the directory from which the INF file was installed)

CD changes the dir

%01% = the dir and path of where the INF is launched from

\.. = goes up one level

\WPI = jumps in the "WPI" folder (where WPI.hta is located)

START /WAIT /B WPI.hta = runs WPI

Edited by ricktendo64
Link to comment
Share on other sites

That is very odd then, my folder structure is identical to what is show on the wpi site, and the $oem$ directory is unrared and placed directly at the root. For some reason my setup just doesnt like that command?

Do you know, is any of this dependant on the hard drive and roms being a certain drive letter? Thats the only other think that may be different on my test system.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...