vpekulas
Posts: 9
Joined: Fri Jan 04, 2008 7:25 pm

SQL Server Connection props as defined by the user

Hello,

I'm in the mids of evaluating the AI and I love it so far :) Thanks for making this app!

The question I have is regarding the SQL server connection where I want the DB, username, password and server address be defined by the user during the installation and then be used by the AI to run the SQL script.

How can I do this or can I even do this ?

Secondary question related to the above is; do I add a driver under ODBC section for the SQL server or can I simply add the DataSource where I just set it to SQL Native Client.

Thanks so much for your time!
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Hi,
The question I have is regarding the SQL server connection where I want the DB, username, password and server address be defined by the user during the installation and then be used by the AI to run the SQL script.
This information can be set by adding the "SQLConnectionDlg" dialog in the "Dialogs" page:
http://www.advancedinstaller.com/user-g ... alogs.html

You can use the properties of the edit boxes on this dialog (for example "ODBC_RES_PROP" for the "ODBC Resource" edit box) when you set the SQL Connection in the "SQL Scripts" page.
http://www.advancedinstaller.com/user-g ... l-sql.html
http://www.advancedinstaller.com/user-g ... ction.html
do I add a driver under ODBC section for the SQL server or can I simply add the DataSource where I just set it to SQL Native Client.
You can use the method you want because they both work. Please note that Advanced Installer automatically lists in the ODBC Driver/Data Source combo the available SQL drivers/data sources.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
vpekulas
Posts: 9
Joined: Fri Jan 04, 2008 7:25 pm

Thanks Cosmin. One more questions, you say that there is a combo box with the available ODBC sources, however when I look at the SQLDialog the ODBC Resource is a text box with prop ODBC_RES_PROP. Can it be changed ?
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Hi,
One more questions, you say that there is a combo box with the available ODBC sources, however when I look at the SQLDialog the ODBC Resource is a text box with prop ODBC_RES_PROP.
Note that I was referring to the "ODBC Driver" combo in the "SQL Connection" page, not to the "ODBC Resource" edit box in the "SQLConnectionDlg" dialog.
Can it be changed ?
Yes, the edit box can be changed to a combo box by using the Dialog Editor:
http://www.advancedinstaller.com/user-g ... ditor.html
Note that the Dialog Editor feature is available only in an Enterprise project.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”