The knowledge base is no longer actively updated, we have moved all content to our Community Support Forum

How can I direct the installer to ask the user to enter a file or directory?

Author: BitRock Support       Date: October 30, 2007 09:33       Tags: User input and custom installer pages

You can direct the installer to ask the user to enter a file or directory using a file or directory parameter. You will have to include a section like the following inside the parameterList section of your installer project file.

    <directoryParameter>
           <name>mydir</name>
           <value></value>
           <title>Title for you directory page</title>
           <description>Some Directory</description>
           <explanation>Please specify the directory requested</explanation>
           <default></default>
           <cliOptionName>prefix</cliOptionName>
           <ask>yes</ask>
           <mustBeWritable>yes</mustBeWritable>
    </directoryParameter>
This will create an installer environment variable called
mydir
that will contain the directory or file introduced by the user. You can later refer to the value of the variable using ${mydir}. Click here to download a sample project.xml file that integrates this functionality.

 

Comments

Create new directory

Author: sTaX       Date: May 20, 2011 11:31

Hi,

it is possible that the user can create a new directory throw the dialog?


Create new directory

Author: BitRock Support       Date: May 20, 2011 14:34

Hi sTaX.

It depends on which execution mode you are using. In particular, then non-Qt version of InstallBuilder does not include the “Create Directory” button.

Best regards,

Juanjo.


Create new directory

Author: sTaX       Date: May 21, 2011 11:36

Thanks for your fast reply.

I use the “BitRock InstallBuilder Multiplatform Enterprise” on a Windows XP-System.

I only want to build a installer for Windows-systems.

Is it right, that there is no chance to get an create-button?

Thanks