corelibraries-devexpress-dot-dataaccess-dot-dataconnectionbase-a69ad151.md
Gets or sets the name of a data connection.
Namespace : DevExpress.DataAccess
Assembly : DevExpress.DataAccess.v25.2.dll
NuGet Package : DevExpress.DataAccess
[Browsable(false)]
public string Name { get; set; }
<Browsable(False)>
Public Property Name As String
| Type | Description |
|---|---|
| String |
A String that specifies the name of a data connection.
|
The following code snippets (auto-collected from DevExpress Examples) contain references to the Name property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
reporting-winforms-wizard-data-connections/CS/T119350/CustomConnectionStorageService.cs#L21
DefaultStorage.Contains(connectionName) ||
GetConnectionsFromXml().Any(c => string.Equals(c.Name, connectionName)) :
GetConnectionsFromXml().Any(c => string.Equals(c.Name, connectionName));
return IncludeApplicationConnections ?
DefaultStorage.Contains(connectionName) || ConnectionProviderService.GetConnectionsFromXml().Any(c => string.Equals(c.Name, connectionName)) :
ConnectionProviderService.GetConnectionsFromXml().Any(c => string.Equals(c.Name, connectionName));
// Loads only the Categories and Products tables for the nwindConnection connection.
if (connection.Name == "nwindConnection") {
if (tables != null) {
// Loads only the Categories and Products tables for the NWindConnectionString connection.
if (connection.Name == "NWindConnectionString") {
if (tables != null) {
// Loads only the Categories and Products tables for the NWindConnectionString connection.
if (connection.Name == "NWindConnectionString") {
if (tables != null) {
reporting-winforms-wizard-data-connections/VB/T119350/CustomConnectionStorageService.vb#L19
Private Function Contains(ByVal connectionName As String) As Boolean Implements IConnectionStorageService.Contains
Return If(IncludeApplicationConnections, DefaultStorage.Contains(connectionName) OrElse GetConnectionsFromXml().Any(Function(c) String.Equals(c.Name, connectionName)), GetConnectionsFromXml().Any(Function(c) String.Equals(c.Name, connectionName)))
End Function
Private Function IConnectionStorageService_Contains(ByVal connectionName As String) As Boolean Implements IConnectionStorageService.Contains
Return If(IncludeApplicationConnections, DefaultStorage.Contains(connectionName) OrElse ConnectionProviderService.GetConnectionsFromXml().Any(Function(c) String.Equals(c.Name, connectionName)), ConnectionProviderService.GetConnectionsFromXml().Any(Function(c) String.Equals(c.Name, connectionName)))
End Function
' Loads only the Categories and Products tables for the nwindConnection connection.
If connection.Name = "nwindConnection" Then
If tables IsNot Nothing Then
' Loads only the Categories and Products tables for the NWindConnectionString connection.
If Equals(connection.Name, "NWindConnectionString") Then
If tables IsNot Nothing Then
See Also