Page 1 of 1

Delete folder and files after installation has finished

Posted: Wed Feb 27, 2008 4:55 am
by rlaemmler
I temporarily need to deploy a tool and run it only during installation. After installation has finished I want to have that folder and all its files deleted.

If I call "Recursively Delete Files $TARGETDIR$\\SharpTouch\\MSAA20\\*" it removes all the files but the folder remains. Any idea how I can do that?

Reto
http://www.exor.ch

Posted: Wed Feb 27, 2008 12:32 pm
by Roostar2004
I don't think you can do somthing like that in installaware (Seems like a missing peice that should be added) but if you create batch file that you place in

$TARGETDIR$\\SharpTouchthat deletes the folder you wish to be deleted and then from installaware call

Recursively Delete Files $TARGETDIR$\\SharpTouch\\BATCHFILE.bat

I think that should be a suitable workaround.

Posted: Wed Feb 27, 2008 5:22 pm
by jimo
It really quite simple;
Use the File Bag or include your temporary tool in support files.
Both of these oiptions get cleaned up automagically when setup finishes.