PDA

View Full Version : File left after uninstall



darkchip
11-25-2004, 09:24 AM
I created and installer which installs a directory struture which my program adds files and folders too. But on the uninstall the file stucture is left there i was to be able to complete delete the directory struture that i created.

:confused:

thanks

ahamed
11-25-2004, 10:15 AM
Hi

Can you rephrase your question.I may help you if you do so.I ask this request since i feel you are online now.

Regards
Ahamed

darkchip
11-25-2004, 10:56 AM
Ok ill try again to exsplain my problem. I created an installer works correctly no problems. When I go to uninstall that program files are left behind.

example
c:\mysoftware\
james\myprogram.exe
storage\data.mdb

When i do my uninstall i want c:\mysoftware and any file structure lower to be deleted.

ahamed
11-26-2004, 12:30 AM
Hi

Can you check whether the files residing after uninstallation are of read only attribute set.Since this could be one sort of a problem causer.

Suraj

ahamed
11-26-2004, 12:56 AM
Hi

Sorry for that delay.I was struck out here.

If the previous state didnt work try these steps

1.Get on to the files property in IDE

2.Right click the file you want to set the uninstall feature

3.Click Properties

4.Select the Advanced Tab

5.In the Installation/uninsatllation property check out permanent is unchecked,if checked Uncheck that.

Try the uninstallation again.This could probably sort the issue.

If you are not able to overcome the problem still, or not able to follow the above steps feel free getting me the status.I may help you to overcome the issue.

Regards
Ahamed

jain.rajat
11-26-2004, 04:24 AM
Hi!
I think these files are the ones which your program has created on execution rather than installed by the installer. By default on removal of a program any log files or data files created by the user are not deleted and hence even the folder is left undeleted. I am not sure about the force directory deleting property prbably you can define a custom action for it. If there is only one fixed file and you want to delete it after un-installation you can package that blank file in the installation and then it will let you delete it.
regards,
Rajat Jain

darkchip
11-26-2004, 08:36 AM
Thanks for the ideas all of you. Sorry for the delay in answering. The perment checks are unchecked and where never on so that did not correct my problem.

jain.rajat
you are correct i do add those files with my program after words. So i guess the only way to delete them is with a custom function :( . If any one has made such a dll or vbscript befor it would save me some time. thanks for everything.

faheemtahir
01-06-2005, 04:49 AM
just use following code as uninstallation begins and remove all files attributes, all files will be deleted.
following code removes all attributes of all files in the install dir, u can also change as u desire

nFileFindResult = FindAllFiles (INSTALLDIR , "*.*" ,szFileName , RESET);
nFileAttributeResult = SetFileInfo(szFileName , FILE_ATTRIBUTE , FILE_ATTR_NORMAL , "");
while (nFileFindResult == 0)
nFileAttributeResult = SetFileInfo(szFileName , FILE_ATTRIBUTE ,FILE_ATTR_NORMAL , "");
nFileFindResult = FindAllFiles(INSTALLDIR , "*.*", szFileName, CONTINUE);
endwhile;

TsungH
01-06-2005, 01:16 PM
Faheem, InstallScript code cannot be used in InstallShield X Express Edition.