a.rasoulain
Posts: 8
Joined: Sat Aug 17, 2013 7:13 am

Writing in Config file

Hi,
My application has two editions.(client and server)
I want to create a setup for client edition.
client version reads data from database on server.
How can i create a setup that set server IP in my config file based on user input.
My configuration file is near my exe.

Any Help would be appreciated in advance.

Armin
Teodor
Posts: 73
Joined: Thu Jul 25, 2013 9:56 am

Re: Writing in Config file

Hi
a.rasoulain wrote:client version reads data from database on server.
How can i create a setup that set server IP in my config file based on user input.
My configuration file is near my exe.
Advanced Installer has support for editing any configuration file of the following types: If you have other questions, please let us know.

Best regards
Teodor Micu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
sipelgas
Posts: 7
Joined: Wed Oct 09, 2013 1:29 pm

Re: Writing in Config file

Hello,

The transform XML works good, for the first install,


But in Maintenance Mode, the Xml config is not done.
I didn't see options Install/Uninstall or Maintenance unlike CustomAction execution stage condition.

Thank you in advance for your response.
Teodor
Posts: 73
Joined: Thu Jul 25, 2013 9:56 am

Re: Writing in Config file

Hi
sipelgas wrote:But in Maintenance Mode, the Xml config is not done.
I didn't see options Install/Uninstall or Maintenance unlike CustomAction execution stage condition.
This is expected behavior due to Windows Installer design. The XML file is included in one (or several) specific product feature(s), thus the action to edit the XML file is performed only if the feature is also installed. During maintenance, that specific feature is already installed and thus no action is taken by Windows Installer.

The good news is that Advanced Installed can help you overcome this limitation with the help of Reinstall one or more features predefined custom action. You can add this custom action to be executed when the user will click on the Next button on your custom dialog (from Maintenance dialogs group) via the Published Events section.

I've attached a sample project to help you with the implementation. My custom dialog is Port_number.
AI f26626.zip
AI f26626 sample project
(3.95 KiB) Downloaded 378 times
If you have other questions, please let us know.
Teodor Micu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
sipelgas
Posts: 7
Joined: Wed Oct 09, 2013 1:29 pm

Re: Writing in Config file

Thank you, It's work very well.

I just needed to add a new conditional for my custom actions : Where I had with &Feature=3, I needed to add OR &Feature = 5.

Return to “Building Installers”