Jump to content

Recommended Posts

Posted (edited)

How can I make my cleanup.cmd invisible in wpi window and run it always after all programs are installed? Means last step of installation is always the cleanup, without option to check or uncheck it.

Anybody some suggestion? maybe change one of the .js or make a new point in config,js?

Edited by wixfigura

Posted
How can I make my cleanup.cmd invisible in wpi window and run it always after all programs are installed? Means last step of installation is always the cleanup, without option to check or uncheck it.

Anybody some suggestion? maybe change one of the .js or make a new point in config,js?

i believe the only way youll ever make your cleanup seem invisable is to use the @ key before all lines of your cleanup script to give it the power of the command but the hidden feel you may be looking for

example

@RD /S /Q "%ALLUSERSPROFILE%\Start Menu\Programs\Mozilla Firefox"

@Del "%ALLUSERSPROFILE%\Desktop\Mozilla Firefox.lnk"

hope that helps

Posted (edited)

wixfigura,

You can always add cleanup command to wpi.exe (you would have to modify wpi.au3 found in the tools folder of WPI4.4rc1, then recompile). This script will give you the flexibility of running any commands before or after the launch of wpi.hta. The script already contains a placeholder for reboot, cleanup, resolution changer and syntax for adding new commands.

;Cleaning up the desktop.
$cleanup = "del /s/q "& chr(34) & "%userprofile%\desktop\*.lnk" & chr(34)
;Run(@ComSpec & " /c " & "start " & $cleanup,"",@SW_HIDE)

Just uncomment/remove the";" in front of Run and change the $cleanup to indicate the file you wish to run.

Example:

Run(@ScriptDir & "\cleanup.cmd", "", @SW_MAXIMIZE)

Where cleanup.cmd would be in the root of where wpi.exe lives and contains all the functions you wish to run for the cleanup.

Edited by lawrenca
Posted

Hi

you havent understood right. I want to include cleanup-script into wpi, but not being visible in the wpi-window. But always in the following runonceex. Now i have it in the wpi.exe. Its just a cosmetical change.

Posted
Hi

you havent understood right. I want to include cleanup-script into wpi, but not being visible in the wpi-window. But always in the following runonceex. Now i have it in the wpi.exe. Its just a cosmetical change.

I believe lawrenca way isnt visible at all? Please read his post again...

Posted

I use a program that hides the console window (so it never shows up at all). I don't remember it's original file name, but for me it's something like this:

_hide cleanup.cmd

Pretty simple, actually. And, of course, I have all of my cleanup stuff in cleanup.cmd.

Posted

Inside WPI.cmd there is a line to run a clean up script. Just remove the REM and rename it to your file. And use

cmdow @ /HID

@ECHO OFF

as the first 2 lines.

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...