Data Link Properties Dialog Box
The Data Link Properties dialog box is the standard Windows system interface for configuring connection strings to data sources. This dialog box exposes all of the properties that the selected OLE DB provider supports. A link to the resulting data connection is displayed under the Data Connections node in the Server Explorer.
To access this dialog box in Visual Studio .NET, select Connect to Database from the Tools menu or click the Connect to Database icon in Server Explorer. You also can open this dialog box by double-clicking a universal data link (.udl) file in Windows Explorer, and in a variety of other ways, including programmatically.
The Data Link Properties dialog box contains four tabs: Provider, Connection, Advanced, and All. The settings available on the latter three tabs depend upon the Provider selected.
Provider
Use the Provider tab of the Data Link Properties dialog box to select the appropriate OLE DB provider for the type of data you want to access. Not all applications make it possible for you to specify a provider or modify the current selection; this tab is displayed only if your application makes it possible for you to edit the choice of OLE DB provider. For more information, see Information on Data Link Properties and OLE DB Providers and Data Access Technologies.You can save a data link with the application itself, or save the provider name string in a separate Universal Data Link (.udl) file. For more information, see Creating and Configuring Universal Data Link (.udl) Files and Configuring Data Controls to Use Universal Data Link (.udl) Files.
Connection
Use the Connection tab of the Data Link Properties dialog box to specify where your data is located and how to connect to it using an OLE DB provider. The connection information can be represented using a common string format. This tab opens by default when you double-click a data connection in Server Explorer.Note The fields displayed on this tab depend upon the OLE DB Provider selected. For example, if you select the OLE DB Provider for Oracle, the Connection tab displays fields for the server name and login. If you select the OLE DB Provider for SQL Server, then the server name, type of authentication, and database must be furnished.
The following table describes the most common connection options.
Option | Description |
---|---|
Data Source | Enter the name of the data source you want to access, typically a server name. |
Location | Enter the location of the data source you want to access, typically a database name. |
Use Windows NT integrated security | Click to use an authentication service to identify yourself.
To use this feature, your OLE DB provider must support an authentication service. The OLE DB Provider for SQL Server is an example. You also must have permissions in the data source to use the authentication service. |
Use a specific user name and password | Select to use a supplied user name and password to authenticate your logon information to the data source. |
User name | Enter the User ID to use for authentication when you log on to the data source. |
Password | Enter the password to use for authentication when you log on to the data source. |
Blank password | Enables the specified provider to return a blank password in the connection string. |
Allow saving password | Allows the password to be saved with the connection string. Whether the password is included in the connection string depends on the functionality of the calling application.
If saved, the password is returned and saved unmasked and unencrypted. |
Enter the initial catalog to use | Enter the catalog that you want to access upon connection. |
Test Connection | Select to attempt a connection to the specified data source. If no connection is made, review the settings. Spelling errors or case sensitivity can block connections. |
Advanced
Use the Advanced tab of the Data Link Properties dialog box to view and set other initialization properties for your data. The Advanced tab is provider-specific and displays only the initialization properties required by the selected OLE DB provider. For more information about advanced initialization properties, refer to the documentation provided with each specific OLE DB provider.All
Use the All tab of the Data Link Properties dialog box to view and edit all OLE DB initialization properties available for your OLE DB provider. Properties can vary depending on the OLE DB provider you are using. For more information about the initialization properties, refer to the documentation provided with each specific OLE DB provider.**Tip **You can open the Edit Property Value dialog box by double-clicking the desired property.
See Also
Connecting to Remote Resources with Server Explorer | Introduction to Server Explorer | Accessing and Initializing Server Explorer | Databases in Server Explorer | Displaying Data Sources in Server Explorer | Adding Items from Server Explorer