substitute a variable in a text file - 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!

srishmawi
Posts: 21
Joined: Tue Jul 07, 2009 2:04 pm

substitute a variable in a text file

I have a text file with jdbc properties to connect to the database
username and password and other settings are entered by the user, and these settings should be committed to the text file.
how to do this ?

sample file :

dataSource.username=username
dataSource.password=password
GabrielBarbu
Posts: 2146
Joined: Thu Jul 09, 2009 11:24 am
Contact: Website

Re: substitute a variable in a text file

Hi,

It is always a good practice to store your application's settings in a registry key, an .ini file or an .xml file.
You can easily set up Advanced Installer to edit these files on install time. Please check out our guides on INI files, XML files and Registries .

If you really need to use a text file to store your settings, then you can follow our tutorial on "Writing text into files" using a custom action.

Regards,
Gabriel
Gabriel Barbu
Advanced Installer Team
http://www.advancedinstaller.com/

Return to “Common Problems”