The LoadFromSQLServer method loads the Data Transformation Services (DTS) package from the specified server running an instance of Microsoft® SQL Server™. This includes information held in the objects and collections that belong to the Package2 object.
Package.LoadFromSQLServer ServerName, [ServerUserName], [ServerPassword], _
[Flags], [PackagePassword], [PackageGuid], [PackageVersionGuid], _
[PackageName], [pVarPersistStgOfHost]
Part | Description |
---|---|
Package | Expression that evaluates to an object in the Applies To list. |
ServerName | Server name. |
ServerUserName | Server user name. |
ServerPassword | Server user password. |
Flags | Value from the DTSSQLServerStorageFlags constants indicating user authentication type. |
PackagePassword | Package password if the package is encrypted. |
PackageGuid | Package identifier, which is a string representation of a globally unique identifier (GUID). |
PackageVersionGuid | Version identifier which is a string representation of a GUID. |
PackageName | Package name. |
pVarPersistStgOfHost | Screen layout information associated with a package (for internal use only). |
If PackageVersionGUID is not specified or is blank, the most recent version of the package is retrieved.
HRESULT LoadFromSQLServer(
BSTR ServerName,
BSTR ServerUserName,
BSTR ServerPassword,
DTSSQLServerStorageFlags Flags CPPDEFAULT(= DTSSQLStgFlag_Default),
BSTR PackagePassword CPPDEFAULT(= NULL),
BSTR PackageGuid CPPDEFAULT(= NULL),
BSTR PackageVersionGuid CPPDEFAULT(= NULL),
BSTR PackageName CPPDEFAULT(= NULL),
VARIANT *pUnkPersistStgOfHost CPPDEFAULT(= NULL) );