Replication Programming
CopySubscription Method
The CopySubscription method copies the entire subscription database to the file location specified by the parameter.
Applies To
Syntax
object.CopySubscription filespec
Part | Description |
---|---|
object | Expression that evaluates to an object in the Applies To list. |
filespec | File name and path to which subscription database is copied. |
Remarks
CopySubscription copies a specially prepared database subscription file (typically with an .msf extension) to a Subscriber, attaches it, and receives an immediately synchronized subscription at the original Publisher. CopySubscription creates the .msf file. Use the AddSubscription method with the ATTACH_SUBSCRIPTION option to create the new subscription from the .msf file.
You can use the CopySubscription method to copy a subscription database that contains more than one subscription.
Prototype (C/C++)
HRESULT CopySubscription(BSTR bstrSubscriptionFileName);