lawrenca Posted February 4, 2006 Posted February 4, 2006 (edited) Changelog: 7 Feb 06, 5:00am CSTModified to include new wpi.au3, wpi.exe, and generate.js...thanks mritter for help with a few bugs in code.Writing kTool.ini to Temp directory (Read/Write Path) now...thanks Lost SoulIf used, wpi.exe now provides:Global variable %wpipath%Can use from relative paths - mapping to first available drive letterClosure of mshta.exe after detection of start of installation via kTool or RunOnceEx - Keying on rundll32.exe or kTool.exe process existence.Admin Check...not like we needed it, but...Command line support with profile and timer (i.e. wpi.exe Home 30)Added lines in wpi.au3/wpi.exe:Launch fontinstaller and ResChange Executables (remarked out for now, just remove ; in front of Run line)Launch Shutdown and cleanup (both remarked out for now)Otherwise, you can still launch with wpi.cmdFor those interested, I've been playing around with kTools progress bars..included copies of the pertinentfiles. Thanks again to Kel for a great product and thanks to kenedy, kTools developer.1. Replace the files of your original WPI...I'm using version 4.3.8. Make sure to have backups! (under Common folder) a. optionswizardtemplate.htm b. main.js (under Wpiscripts folder) c. generate.js d. optionswizard.js2. Download kTool v1.1a and add the kTool.exe under the WPI>Tools folder (This drives the progress bars)Details and screenshots can be found here:http://www.msfn.org/board/index.php?s=&sho...ndpost&p=194610I've used WPI as the front-end, modified generate.js to write all the checked Applications to kTool.ini inthe WPI>Tools Directory instead of to the RunOnceEx registry key. Then we launch kTool.exe with kTool.inias the source of installs.3. Add wpi.exe under the WPI root (if you want to use it), see post below...same wpi.exe but different generate.js files:http://www.msfn.org/board/index.php?s=&sho...ndpost&p=4593224. Launch WPI (preferably from the new wpi.exe as it will install global variable %wpipath% to be used in your config.js file and will also take care of any relative path problems, but will still work from wpi.hta or wpi.cmd)5. Click "Options" Button and check 'yes' to "kTool RunOnceEx Progress Bars", then save...Launch Begin Install and you should see your RunOnceEx dialog "look-a-like" on a form with progress bars.Not a lot of testing went into this mod but seems to work o.k. for me. Maybe some tweaking on the way it imports registry info and copy/delete commands.Only throwing it out to the forum to stimulate ideas and discussion.pbWPI_a1.zip Edited February 7, 2006 by lawrenca
Yurek3 Posted February 5, 2006 Posted February 5, 2006 I did try.Work very good.THX for your job .I now use your kTool idea for my undenttender WPi instalations.
Sonic Posted February 5, 2006 Posted February 5, 2006 How works progress bar ? For example I have many apps into SFX, so there is a first progress bar to decompress and second there is batch file to execute some commands and real isntall begin. kTool works with that case ?
Kelsenellenelvian Posted February 5, 2006 Posted February 5, 2006 (edited) Man that is fookin SWEET!!! I am Definatly adding this to WPI!One issue = WPI.EXE does not like to close itself.How works progress bar ? For example I have many apps into SFX, so there is a first progress bar to decompress and second there is batch file to execute some commands and real isntall begin. kTool works with that case ?As far as I can see it brings up a sub progress bar that waits for the installation to finis and the continues on its merry way. Edited February 5, 2006 by kelsenellenelvian
Kelsenellenelvian Posted February 5, 2006 Posted February 5, 2006 Can I see the source code of WPI.exe?
lawrenca Posted February 5, 2006 Author Posted February 5, 2006 (edited) Kel,Can be found here, just download the wpi.au3, Doc Symbiosis' wpi.cmd works well too, didn't find it until I finished my work under that thread "Ideas needed to get rid of cd check".http://www.msfn.org/board/index.php?s=&sho...ndpost&p=459322Code removed and updated at the location below:http://www.msfn.org/board/index.php?s=&sho...ndpost&p=459723Sonic,These progress bars have no real relation to actual thread/process useage in code. It is only displaying the application count progress...the progress bars are only counting up as the number of apps being installed decrease. BTW, with 3 or more commands under any application will also trigger a secondary progress bar under the app being installed, while the one displayed at the bottom is for the total app count. Edited February 5, 2006 by lawrenca
Kelsenellenelvian Posted February 5, 2006 Posted February 5, 2006 Now what about it not liking to be closed at the end of installations?Also can you get it to kill mshta.exe once the installations begin?
lawrenca Posted February 5, 2006 Author Posted February 5, 2006 I'll look into it, also wanted to maintain wpi ability to use command line support for wpi.hta to call in variables/options...next go around!
Kelsenellenelvian Posted February 5, 2006 Posted February 5, 2006 Also how are we gonna call the extras like the fontinstaller and reschanger?
lawrenca Posted February 5, 2006 Author Posted February 5, 2006 (edited) Kel,I believe the exit problem is fixed...Also, closing mshta.exe from within the wpi.exe, couldn't find a better way to do it outside the startup .exe, not a java programmer.Still working on passing in command-line parameters to wpi.hta, don't want to lose that capability.I'll also try to take down/update the previous files with the newer fixed versions.New wpi.exe can be found at start of the thread:http://www.msfn.org/board/index.php?s=&sho...ndpost&p=459446Source code attached here: wpi.au3wpi.au3 Edited February 5, 2006 by lawrenca
lawrenca Posted February 5, 2006 Author Posted February 5, 2006 You can add other executables that can be called from within wpi.exe...add the code to the wpi.au3 from post above. Comment out if you don't want to run these by adding semi-colon ";" without quotes in front of what you don't wish to run and then compile to .exe using autoit. AutoIT is free and can be found here:AutoIT v3Once installed, you should be able to right-click the .au3 file then click "Compile Script". You now have a new wpi.exe.;*****Can add other executables using this syntax*****;Run ( "filename" [, "workingdir" [, flag]] );Where:;filename = The full name of the executable (EXE, BAT, COM, or PIF) to run. ;workingdir [optional] The working directory. ;flag [optional] The "show" flag of the executed program:; @SW_HIDE = Hidden window; @SW_MINIMIZE = Minimized window; @SW_MAXIMIZE = Maximized window ;Force resolution to needed size for wpi interface.Run(@ScriptDir & "\Tools\ResChange.exe -width=1280 -height=1024 -depth=max -refresh=max", "", @SW_MAXIMIZE);Font installation - the smooth and customizable way.Run(@ScriptDir & "\Tools\fonts\fontinstaller.exe", "", @SW_MAXIMIZE)I've added the contents to the wpi.au3 from post:http://www.msfn.org/board/index.php?s=&sho...ndpost&p=459723
lawrenca Posted February 5, 2006 Author Posted February 5, 2006 Think I've finally fixed the exit problems, adding in additonal fontinstaller and ResChange Executables, also added the command-line arguments for Profile and Timer.Posted new wpi.exe and source code, wpi.au3See starting post for new stuff:http://www.msfn.org/board/index.php?s=&sho...ndpost&p=459446Final for now...
Kelsenellenelvian Posted February 6, 2006 Posted February 6, 2006 Now it wont save the option to use kTool.
lawrenca Posted February 6, 2006 Author Posted February 6, 2006 Kel,Fixed a few bugs, reloaded generate.js, wpi.exe, and wpi.au3...summary on first post here with the new files.http://www.msfn.org/board/index.php?s=&sho...ndpost&p=459446
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now