I have a package that I built a while back and now we are getting ready to deploy an alternative application. The original application (once installed) eventually creates custom INI files and user data files in various locations. I've tried creating custom actions within the new application package that will remove these generated files but for some reason it will not work. Does anyone know of any place I could find information on how to get specific files/directories removed via a script within a packaged application (before installation obviously). Simply uninstalling or pulling the GPO from deployment only uninstalls the application and does not removed generated files. I can't seem to find this information anywhere aside from people suggesting to use custom actions... I must be doing something wrong in my custom action. :)
0 Comments   [ + ] Show Comments

Comments

Please log in to comment

Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.

Answers

0
Look up the RemoveFile Table if the package is in the form of MSI.
Answered 03/02/2007 by: AngelD
Red Belt

Please log in to comment
0
I actually figured it out... I neglected to execute the custom action :) But now I have a different issue... apparently I'm only executing this on installation and we need to make sure that when a GPO gets pulled it also removes the files during uninstallation. Where in the Sequences would I put this? I can't find anything regarding uninstall... only install.
Answered 03/02/2007 by: KrakaJap
Senior Yellow Belt

Please log in to comment
0
You need to look at your condition on that CA.

REMOVE=ALL <-- for removal
Not Installed <-- for first install

for example.
Answered 03/02/2007 by: turbokitty
Sixth Degree Black Belt

Please log in to comment
0
Hi There,

You can use the RemoveFile table and specify your files to be removed there. Use "3" in the "Installmode" column to remove the files during Install and Uninstall. That's it! No need to use the scripts for the Custom Action.

Cheers!
Answered 03/05/2007 by: dj_xest
Fifth Degree Black Belt

Please log in to comment
0
Will this remove folders as well as files? Having only a few generated files would be fine for this but what if I had an entire directory full of files? I wasn't aware of InstallMode 3... thanks for the advice!

EDIT: Also... what happens if the file does not exist when you try to delete it with the RemoveFile table? There may also be instances where the user feels they're savvy enough to take care of this on their own and remove the file(s) manually. :) Should they do this I don't want the uninstall to fail because of a missing file... I also do not want them to be notified of an error during uninstall. You probably know as well as I do... any kind of an error or alert on an end-user's machine is reason enough to stop everything because "life as we know it is coming to an end!" LOL
Answered 03/05/2007 by: KrakaJap
Senior Yellow Belt

Please log in to comment
0
Dude,

If you also want to remove a directory, you may need to add again a new row in RemoveFile table and fill up the "FileName" column. Wild cards are also accepted here. You cannot remove a folder until you have cleared up that directory with this RemoveFile table. YOu now have identical rows with an entry on FileName column as their differences.

As far as I know, it won't spit an error even if the files/folders are not there. I've been doing this for every application that I'm doing.. And I will do this until the end of time.. at least with packaging! hehehe
Answered 03/05/2007 by: dj_xest
Fifth Degree Black Belt

Please log in to comment
Answer this question or Comment on this question for clarity