How to read/parse configuration file from command line - Advanced Installer Community

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!

xjluogang
Posts: 20
Joined: Sun Apr 14, 2013 3:24 pm

How to read/parse configuration file from command line

Hi guys,
Is there any way to read the parameters from a file when I run my installer by command line and pass a configuration file? E.g. > MY_INSTALLER.exe -f config.ini
the config.ini contain several section just like below:
------------------------------
[Host]
Address=***
Port=***

[Auth]
User=***
Pswd=***

...
------------------------------

Btw, usually I get following notice when I searching something in Forums, what's the best practices for search?
The following words in your search query were ignored because they are too common words: action custom.
You must specify at least one word to search for. Each word must consist of at least 3 characters and must not contain more than 14 characters excluding wildcards.
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: How to read/parse configuration file from command line

Hello,
Is there any way to read the parameters from a file when I run my installer by command line and pass a configuration file? E.g. > MY_INSTALLER.exe -f config.ini
the config.ini contain several section just like below:
I'm afraid we don't have support for this. However, in order to achieve this you can create a BAT file which will start your EXE installation package with desired command line arguments.
Btw, usually I get following notice when I searching something in Forums, what's the best practices for search?
The following words in your search query were ignored because they are too common words: action custom.
You must specify at least one word to search for. Each word must consist of at least 3 characters and must not contain more than 14 characters excluding wildcards.
In order to perform a forum search we recommend you to use the top right search from our website.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
xjluogang
Posts: 20
Joined: Sun Apr 14, 2013 3:24 pm

Re: How to read/parse configuration file from command line

got you, Thanks man :D
Daniel
Posts: 8283
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: How to read/parse configuration file from command line

You're welcome.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”