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!

shadibaroudi
Posts: 1
Joined: Sat Dec 16, 2017 7:39 am

how I can Rename folder by condition during installation

I have a folder contains files and I want to rename it to a new name by condition
Sorin
Posts: 663
Joined: Mon May 08, 2017 1:03 pm

Re: how I can Rename folder by condition during installation

Hello and welcome to our forums,

Yo could implement this using property based folders. This is the complete method:

1. Go to "Install Parameters" page and define a new property which should contain the folder name. This property could be named, for example "NAME" and should be initialized to a valid path, for example "C:\"

2. Go to "Files and Folders" page and create a new "Property Based" folder based on the above property

3. Go to "Custom Actions" page and create a new "Set installer property" custom action with sequence, configured to run before Paths Resolution action group.

In the "Property" field write the exact name of the previously created property (Ex: "NAME").
In the "Value" field write the new path. This could be a formatted value. For example "[APPDIR]First Folder" or "C:\First Folder"
In the "Condition" enter the condition that has to be true for the folder to be named "First Folder"

Repeat the step 3 for each name/condition pair you need to use.

Best regards,
Sorin
Sorin Stefan - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”