卸载应用程序时删除文件 [英] Delete the file while Uninstall the application

查看:82
本文介绍了卸载应用程序时删除文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在卸载时删除一个与应用程序设置无关的文件.

我怎么能删除那个文件.该文件可能在系统中的任何位置

如果有人知道解决方案,请回复我

谢谢您.

HI friends i want delete the one file which not related to the application setup at the time of uninstall.

how could i delete that file . that file may be at anywhere in system

if any one know the solution please reply me

thanking you

推荐答案

在安装时记下文件的位置,并将其保存在某些文件(config,.ini等)或注册表中.然后,您可以在卸载时快速找到并删除它.
Make a note of the file''s location at installation time and save it in some file (config, .ini etc) or in the Registry. Then you can quickly locate and delete it at uninstall time.


嘿,您只需要创建一个exe文件,然后将其与您的安装程序一起安装在卸载部分即可.在该exe代码中,您有2检查是否所有包含该文件的系统驱动器,都可以使用system.Eviourmnet.getLogicalDrives()方法.
hey u have to just create one another exe an attach it with ur setup and in uninstallation section. In that exe code u have 2 check all systemdrives containing that files or not for it u can use system.Eviourmnet.getLogicalDrives() method.


这篇关于卸载应用程序时删除文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆