共用方式為


IDtsConnectionService.AddConnectionToPackage Method

Adds existing connections to a package designer so that the designer is aware of a new connection manager

命名空間: Microsoft.SqlServer.Dts.Runtime.Design
組件: Microsoft.SqlServer.Dts.Design (in microsoft.sqlserver.dts.design.dll)

語法

'宣告
Function AddConnectionToPackage ( _
    connectionManager As ConnectionManager _
) As Boolean
bool AddConnectionToPackage (
    ConnectionManager connectionManager
)
bool AddConnectionToPackage (
    ConnectionManager^ connectionManager
)
boolean AddConnectionToPackage (
    ConnectionManager connectionManager
)
function AddConnectionToPackage (
    connectionManager : ConnectionManager
) : boolean

參數

  • connectionManager
    The connect manager to register in the package designer.

傳回值

true if the connection is not null, false otherwise.

備註

This function needs to be called only if a connection manager was added directly to the package without going through the CreateConnection method.

執行緒安全性

Any public static (Shared in Microsoft Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

平台

開發平台

如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。

目標平台

如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。

請參閱

參考

IDtsConnectionService Interface
IDtsConnectionService Members
Microsoft.SqlServer.Dts.Runtime.Design Namespace