We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

DeadlyDonger
Posts: 19
Joined: Wed Jan 07, 2015 6:44 pm

Removing specific files and folders from different location

Hi, I want to add a checkbox to the uninstaller of my programs setup which says "Delete all Program Settings". Ideally this should be before the user clicks on the uninstall button on the uninstall dialog so if the user checks the checkbox, while uninstalling the main files, it will remove these files. What this should do is remove two folders in two locations:

C:\Users\xxx\AppData\Roaming\ProductName
C:\Users\xxx\AppData\Local\ProductName

How can I do this?
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Removing specific files and folders from different locat

Hi and welcome to the Advanced Installer forums.

In order to achieve what you want you can follow the steps below:
- go in the "Files and Folders" page and create your folder under the Application Data and Local Application Data folders (you can use the [|ProductName] property as their name)
- right-click on the created folders that you want to remove and use the "Uninstall Cleanup" option for them
- follow the wizard and choose the options you need
- build and test your project

Best regards,
Eusebiu

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
DeadlyDonger
Posts: 19
Joined: Wed Jan 07, 2015 6:44 pm

Re: Removing specific files and folders from different locat

Thank you for the reply, however the program itself creates specific files and folders in that location and not the installer itself. When I uninstall the program, I want those folders which the PROGRAM created and not the installer. That's why I need to know how to access those specific folders.
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Removing specific files and folders from different locat

Hi,

Yes, I understood your request, however you should also create those folders (empty) in the installer, so that it will know where they are located and delete them during the uninstallation.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
DeadlyDonger
Posts: 19
Joined: Wed Jan 07, 2015 6:44 pm

Re: Removing specific files and folders from different locat

Thank you! it works just the way I want it to. That as the solution after all :D
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Removing specific files and folders from different locat

You're welcome. Glad to help.

Just let us know if you have any other question.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
DeadlyDonger
Posts: 19
Joined: Wed Jan 07, 2015 6:44 pm

Re: Removing specific files and folders from different locat

Sorry for the extremely late reply. I DO have one more question. This is regarding the registry. Say I want to add a key to this path: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\

I want my app to be accessible through the Run.EXE command. How would I add a key with my PRODUCTNAME and inside that added key add a REG_EXPAND_SZ and the value of that should be my programs launch path?
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Removing specific files and folders from different locat

Hi,

You can follow the Add registry keys and values to your package tutorial to achieve this.

Please note that all the 32-bit registry entries are added under the "Wow6432Node" section on a 64 bit machine. If you want your registry entry not to be installed under "Wow6432Node" section, you can go in the Organization page and check the "64-bit Component" checkbox for the component that contains it.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
DeadlyDonger
Posts: 19
Joined: Wed Jan 07, 2015 6:44 pm

Re: Removing specific files and folders from different locat

Thank you Eusebiu! I'll take it from here and If there is anything I'll let you know :)
Eusebiu
Posts: 4971
Joined: Wed Nov 14, 2012 2:04 pm

Re: Removing specific files and folders from different locat

You're welcome.

Just let us know anytime you need help.

Best regards,
Eusebiu
Eusebiu Aria - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”