共用方式為


IDtsConnectionService 介面

Provides a service that can be used by various user interfaces to create new connections.

命名空間:  Microsoft.SqlServer.Dts.Runtime.Design
組件:  Microsoft.SqlServer.Dts.Design (在 Microsoft.SqlServer.Dts.Design.dll 中)

語法

'宣告
Public Interface IDtsConnectionService _
    Inherits IDtsConnectionBaseService
'用途
Dim instance As IDtsConnectionService
public interface IDtsConnectionService : IDtsConnectionBaseService
public interface class IDtsConnectionService : IDtsConnectionBaseService
type IDtsConnectionService =  
    interface 
        interface IDtsConnectionBaseService 
    end
public interface IDtsConnectionService extends IDtsConnectionBaseService

IDtsConnectionService 型別公開下列成員。

屬性

  名稱 說明
公用屬性 IsDesignerOnline Gets a value that indicates whether the designer is working in an online mode. (繼承自 IDtsConnectionBaseService。)

上層

方法

  名稱 說明
公用方法 AddConnectionToPackage Adds existing connections to a package designer so that the designer is aware of a new connection manager
公用方法 CreateConnection(String) Creates a new connection using the specified connection type. (繼承自 IDtsConnectionBaseService。)
公用方法 CreateConnection(String, ConnectionManagerUIArgs) Creates a new connection using the specified connection type and argument. (繼承自 IDtsConnectionBaseService。)
公用方法 CreateConnectionFromDataSource Displays a list of existing data sources and allows users to create connection managers based on data sources.
公用方法 EditConnection(ConnectionManager) Edits a specific existing connection and returns a value that indicates whether the connection was modified.
公用方法 EditConnection(ConnectionManager, ConnectionManagerUIArgs) Edits a specific existing connection and returns a value to indicate whether the connection was modified.
公用方法 GetAMOObject Retrieves the AMO object for an OLAP connection.
公用方法 GetConnections Retrieves all connection managers in the current package. (繼承自 IDtsConnectionBaseService。)
公用方法 GetConnectionsOfType Returns all connections of the specified type found in the current package. (繼承自 IDtsConnectionBaseService。)
公用方法 GetDataSource Retrieves the DataSource object for a connection.
公用方法 SetDataSourceID Allows the connection string for a run-time connection manager to be in synchronization with the connection string of a Data Source object, if both are in the same project. This synchronization is done whenever a package is opened in the designer.
公用方法 SetReferencedProject Sets the referenced project to a connection manager.

上層

備註

This service can be used by any kind of user interface, whether that be a task, connection manager, transform, log provider, or others.

範例

The following code example shows the use of the IDtsConnectionService.

IDtsConnectionService dtsConnectionService = serviceProvider.GetService(typeof(IDtsConnectionService)) as IDtsConnectionService;

請參閱

參考

Microsoft.SqlServer.Dts.Runtime.Design 命名空間