This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallShield
- :
- InstallShield Forum
- :
- multiple connection for Multiple SQLLogin
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 28, 2009
07:00 PM
multiple connection for Multiple SQLLogin
Hi,
I am using multiple SQLLogin dialogues to get the user to supply the different db names and connection info.
under BtnSQLBrowse i have
[IS_SQLSERVER_LIST] [IS_SQLSERVER_LOGSERVER] 1
[IS_SQL_DB_BROWSE] 0 1
[IS_SQL_SERVER_BROWSE]1 1
[IS_SQLBROWSE_INTRO] [IS_SQLBROWSE_INTRO_SERVER] 1
DoAction ISSQLServerList 1
SpawnDialog SQLBrowse 1
under BtnDbBrowse dialogue behaviour i have
[IS_SQLSERVER_LIST] [IS_SQLSERVER_LOGDATABASE] 1
[IS_SQL_DB_BROWSE] IS_SQLSERVER_LOGDATABASE 1
[IS_SQL_SERVER_BROWSE] 0 1
[IS_SQLBROWSE_INTRO] [IS_SQLBROWSE_INTRO_DB] 1
DoAction ISSQLQueryDatabases 1
SpawnDialog SQLBrowse IS_SQLSERVER_STATUS=0
similarly, for the other two SQLLogin dialogues, i have exactly same as above except LOG is replaced by ALARM and TTS
I have created 3 connection in the SQL script view.
NewSQLConnection1
NewSQLConnection2
NewSQLConnection3
under advanced tab in that view, i have changed the property name to be
IS_SQLSERVER_LOGSERVER
IS_SQLSERVER_LOGDATABASE
IS_SQLSERVER_AUTHENTICATION
IS_SQLSERVER_LOGUSERNAME
IS_SQLSERVER_LOGPASSWORD
similarly for the other two connections i only replaced 'LOG' above by 'ALARM' and 'TTS'
I also created 3 SQLBrowse dialogues as each connection can have different list of DB.
I do not have any sql scripts. The only purpose for these dialogues is to allow the user to enter the information of the database connection and selection of the database from the list, which i use for other purpose.
Single SQLLogin (with only NewSQLConnection1) works fine.
But once i create the three sql connections, i am getting
"Error 27502. Could not connect to Microsoft SQL Server ". [DBNETLIB] [ConnectionOpen (Connect()).]SQL Server does not exist or access denied. (17) "
Can someone please help me?
Thank you.
I am using multiple SQLLogin dialogues to get the user to supply the different db names and connection info.
under BtnSQLBrowse i have
[IS_SQLSERVER_LIST] [IS_SQLSERVER_LOGSERVER] 1
[IS_SQL_DB_BROWSE] 0 1
[IS_SQL_SERVER_BROWSE]1 1
[IS_SQLBROWSE_INTRO] [IS_SQLBROWSE_INTRO_SERVER] 1
DoAction ISSQLServerList 1
SpawnDialog SQLBrowse 1
under BtnDbBrowse dialogue behaviour i have
[IS_SQLSERVER_LIST] [IS_SQLSERVER_LOGDATABASE] 1
[IS_SQL_DB_BROWSE] IS_SQLSERVER_LOGDATABASE 1
[IS_SQL_SERVER_BROWSE] 0 1
[IS_SQLBROWSE_INTRO] [IS_SQLBROWSE_INTRO_DB] 1
DoAction ISSQLQueryDatabases 1
SpawnDialog SQLBrowse IS_SQLSERVER_STATUS=0
similarly, for the other two SQLLogin dialogues, i have exactly same as above except LOG is replaced by ALARM and TTS
I have created 3 connection in the SQL script view.
NewSQLConnection1
NewSQLConnection2
NewSQLConnection3
under advanced tab in that view, i have changed the property name to be
IS_SQLSERVER_LOGSERVER
IS_SQLSERVER_LOGDATABASE
IS_SQLSERVER_AUTHENTICATION
IS_SQLSERVER_LOGUSERNAME
IS_SQLSERVER_LOGPASSWORD
similarly for the other two connections i only replaced 'LOG' above by 'ALARM' and 'TTS'
I also created 3 SQLBrowse dialogues as each connection can have different list of DB.
I do not have any sql scripts. The only purpose for these dialogues is to allow the user to enter the information of the database connection and selection of the database from the list, which i use for other purpose.
Single SQLLogin (with only NewSQLConnection1) works fine.
But once i create the three sql connections, i am getting
"Error 27502. Could not connect to Microsoft SQL Server ". [DBNETLIB] [ConnectionOpen (Connect()).]SQL Server does not exist or access denied. (17) "
Can someone please help me?
Thank you.
(2) Replies
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Jan 29, 2009
11:08 AM
I would suggest that you will generate a Windows Installer verbose log to find out how the properties associated with your SQL connections get set.
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
‎Feb 05, 2009
05:51 PM
http://community.acresso.com/archive/index.php?t-171252.html
I have tried the instructions in the above link with a few changes as below:
These same steps could be used to add 2 or more SQLLogin dialogs
To display 2 SQL connection dialogs at runtime, one for each connection, do the following:
1- Add 2 (or as many as you need) SQLConnections to the SQL Servers view (Server Confguration>SQL Scripts).
2- Add the property: IS_SQLSERVER_CONNECTIONS_TO_VALIDATE
3-Go to the Dialog editor and expand the SQLLogin dialog.
Add the following event to the Next button and place it before the DoAction event:
[IS_SQLSERVER_CONNECTIONS_TO_VALIDATE] 1
where is the name of the second connection you want to validate.
4-Rename SQLLogin to SQLLogin2.
5-Export SQLLogin2 to a dialog file.
6-Rename SQLLogin2 to SQLLogin.
7-Repeat step 3,4,5,6 for as many sql connection (SQLLogin dialogues ie SQLLogin3,SQLLogin4 etc) you have with the corresponding
8-Change of the event you added to where is the name of the first connection you want to validate.
9-Import SQLLogin2 from the dialog file you exported earlier.
10- Create new properties as required for the different fields of each SQLLogin i.e Server name, username, database name etc.
For example, if these 2 connections connect to 2 different servers but the database name and the authentication information is the same,
then create a new property for the Server name.
11- In SQL Script view, for every field that is different between the 2 connections, assign a unique property name (created in step 10)
(the advanced tab).
12-Change the event for the Next button of the SQLLogin dialog to display the SQLLogin2 dialog.
13-Change the event for the Next button of the SQLLogin2 dialog to display the SetupType dialog (or whatever dialogue you need),
and the Back button to display the SQLLogin dialog.
14-Change the event for the Back button of the SetupType dialog to display the SQLLogin2 dialog.
15-Add the following event to the BtnDbBrowse button on the SQLLogin dialog and place it before the DoAction event:
[IS_SQLSERVER_CONNECTIONS_TO_VALIDATE] 1
where is the name of the first connection you want to validate
16-Add the following event to the BtnDbBrowse button on the SQLLogin2 dialog and place it before the DoAction event:
[IS_SQLSERVER_CONNECTIONS_TO_VALIDATE] 1
where is the name of the second connection you want to validate.
17- You will need to clone SQLBrowse dialogue ( right click on the dialogue name) for each SQLLogin that has a different list of DB displayed.
18- For each SQLBrowse dialoague, under the Behaviour node, for control name 'OK', change the Event Names to correspond to the property you
created in the corresponding SQLLogin dialogue (ie database name property)
19- For the each SQLLogin Dialogue, change the event to the BtnDbBrowse button for SpawnDialogue to correspond to correct SQLBrowse (ie SQLBrowse1)
I have tried the instructions in the above link with a few changes as below:
These same steps could be used to add 2 or more SQLLogin dialogs
To display 2 SQL connection dialogs at runtime, one for each connection, do the following:
1- Add 2 (or as many as you need) SQLConnections to the SQL Servers view (Server Confguration>SQL Scripts).
2- Add the property: IS_SQLSERVER_CONNECTIONS_TO_VALIDATE
3-Go to the Dialog editor and expand the SQLLogin dialog.
Add the following event to the Next button and place it before the DoAction event:
[IS_SQLSERVER_CONNECTIONS_TO_VALIDATE]
where
4-Rename SQLLogin to SQLLogin2.
5-Export SQLLogin2 to a dialog file.
6-Rename SQLLogin2 to SQLLogin.
7-Repeat step 3,4,5,6 for as many sql connection (SQLLogin dialogues ie SQLLogin3,SQLLogin4 etc) you have with the corresponding
8-Change
9-Import SQLLogin2 from the dialog file you exported earlier.
10- Create new properties as required for the different fields of each SQLLogin i.e Server name, username, database name etc.
For example, if these 2 connections connect to 2 different servers but the database name and the authentication information is the same,
then create a new property for the Server name.
11- In SQL Script view, for every field that is different between the 2 connections, assign a unique property name (created in step 10)
(the advanced tab).
12-Change the event for the Next button of the SQLLogin dialog to display the SQLLogin2 dialog.
13-Change the event for the Next button of the SQLLogin2 dialog to display the SetupType dialog (or whatever dialogue you need),
and the Back button to display the SQLLogin dialog.
14-Change the event for the Back button of the SetupType dialog to display the SQLLogin2 dialog.
15-Add the following event to the BtnDbBrowse button on the SQLLogin dialog and place it before the DoAction event:
[IS_SQLSERVER_CONNECTIONS_TO_VALIDATE]
where
16-Add the following event to the BtnDbBrowse button on the SQLLogin2 dialog and place it before the DoAction event:
[IS_SQLSERVER_CONNECTIONS_TO_VALIDATE]
where
17- You will need to clone SQLBrowse dialogue ( right click on the dialogue name) for each SQLLogin that has a different list of DB displayed.
18- For each SQLBrowse dialoague, under the Behaviour node, for control name 'OK', change the Event Names to correspond to the property you
created in the corresponding SQLLogin dialogue (ie database name property)
19- For the each SQLLogin Dialogue, change the event to the BtnDbBrowse button for SpawnDialogue to correspond to correct SQLBrowse (ie SQLBrowse1)