Skip to main content

Select a Connection String

This page allows you to specify a connection string used to establish a data connection. The following options are available:

Default Connection String

Choose the default connection string if it is specified in the application’s configuration file.

EF default connection string

Custom Connection String

Specify a custom connection string in the connection string editor and choose whether or not to store the string in the application’s configuration file.

how-to-ef-datasource-specify-connection-string

See Connection Strings in the ADO.NET Entity Framework for more information.

Note

When you specify a custom connection string in the Data Source wizard, the password is obscured with asterisk characters (the number of characters does not correspond to the actual length of the password). To learn more, see Data Access Security.

Predefined Connection String

Select an existing connection string available in the current project.

how-to-ef-datasource05

Note

For .NET projects, install Microsoft.Extensions.Configuration and Microsoft.Extensions.Configuration.Json to obtain a data connection string from appsettings.json when you select a predefined data connection in the Data Source Wizard.

Click Next to proceed to the next wizard page. If the current Entity Framework model contains stored procedures, go to the Bind to a Stored Procedure page; otherwise, proceed to the Configure Filters page.