Mrashwan32
Posts: 4
Joined: Fri Nov 30, 2018 2:54 pm

Get user's inputs data within installation

Hello,

I just using advanced installer recently,
I have an issue with my program packaging.

I need to collect user inputs within installati9n and save it to x.txt in app folder to allow app to use it to create addmi account in user's table of db.
I followed many articles discussed it before but, i didn't success, beacuse i wasn't understand how to set property for multi data (full name, username, password, etc) to write it in same file.
tha main problem for me is:
I want to collect multi data as below;
- First page (dialog) collect: fullname - email- username - password. And write all of it in x.txt file.
*** and is there any way to delete the file after db used this data.

- next page (next dialog) collect servername and port, and write it to another file but in one line as: servername:port.

Any help.
Catalin
Posts: 6586
Joined: Wed Jun 13, 2018 7:49 am

Re: Get user's inputs data within installation

Hello and welcome to our forums,

In order to achieve what you want, you can proceed as it follows:

- First of all, you need to create an empty text file and add it to your project (in the "Files and Folders" page)

- Now let me explain few things. First of all, all dialog controls of the "EditBox" type (the boxes where you type some information: e.g. e-mail, name, etc.) have properties assigned to them. For instance, if you go on your first dialog and click on any of the edit boxes, on the right pane, under "Property", you will see the property name (e.g. USERNAME, PASSWORD, etc.) That is the property which stores the value that the user inputs at install time.

- Now that we have made that clear, it is time to edit our earlier added text file, using the "New Text File Update" feature. To do so, simply go to "Files and Folders" page and click on the "New Text File Update" button from the Toolbar.

In the "Include:" field, input the name of your text file (e.g. myFile.txt). After doing so, click on "Append/Create" and, in the "File Content" field, insert the properties that contain the values the user inputs.

E.g. : [YOUR_PROPERTY_1]-[YOUR_PROPERTY_2]

Hope this helps.

Kind regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
Mrashwan32
Posts: 4
Joined: Fri Nov 30, 2018 2:54 pm

Re: Get user's inputs data within installation

Thanks for reply, i solved it already with reading your documentation.
but, is there any way to write to this file according to user selection in dlg process, i mean specifically, write data according to conditions, so this data maybe changed.
Catalin
Posts: 6586
Joined: Wed Jun 13, 2018 7:49 am

Re: Get user's inputs data within installation

Hello,
but, is there any way to write to this file according to user selection in dlg process, i mean specifically, write data according to conditions, so this data maybe changed.
I am not sure I understand this. Can you please try to be more specific (maybe exemplify) about what you want to achieve?

Regards,
Catalin
Catalin Gheorghe - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”