jonyelton
Posts: 1
Joined: Mon Sep 10, 2012 10:48 pm

Custom Variables and ini files

I have been tasked with updating our client installers after 10 plus years. I am new to this, and any pointers will be great. I am basing my needs off of what the old installer did,

I want the installer to require as little user intervention as possible. We accomplish this with a simple ini file located in root folder of the installer.

In the file, we have some variables that we want the installer to use as variables. For example,

Server=FS1
Database=DB1

I want the installer to create registry keys that populates the key with this variable information. I also want the installer to create a shortcut on the users desktop and it will need the server name to do this (and thus need the variable). I do not want to prompt the end user to populate this information, as they won't know it.

Can this be accomplished?
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Custom Variables and ini files

Hello and welcome to Advanced Installer froums,

Thank you for your interest in Advanced Installer.

In order to achieve what you want you can use two public properties which will set your INI entries values, your registries values and your shortcut name.

Here's the steps to proceed:
- Go to "Install Parameters" page and define two public properties like this:
  • Name: MY_SERVER
    Value: FS1

    Name: MY_DATABASE
    Value: DB1
- Go to "Files and Folders" view and edit the INI file entries like this
  • Key: Server
    Value: [MY_SERVER]

    Key: Database
    Value: [MY_DATABASE]
- In the "Shortcut Properties" dialog set your shortcut "Name" field with [|MY_SERVER].
- Go to "Registry" page and create two registries values like this:
  • Name: Server_Value
    Data: [MY_SERVER]

    Name: Database_Value
    Data: [MY_DATABASE]
- Build and run your project.

Let us know if this helps, otherwise give us more details about your scenario.

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

Return to “Building Installers”