This document is archived and information here might be outdated.  Recommended version.

IWorkspaceFactory.Copy Method (ArcObjects .NET 10.7 SDK)
ArcObjects Help for .NET developers > ArcObjects Help for .NET developers > ArcObjects namespaces > Geodatabase > ESRI.ArcGIS.GeoDatabase > Interfaces > IW > IWorkspaceFactory Interface > IWorkspaceFactory.Copy Method
ArcGIS Developer Help

IWorkspaceFactory.Copy Method

Copies a workspace to the specified destination folder.

[Visual Basic .NET]
Public Function Copy ( _
    ByVal WorkspaceName As IWorkspaceName, _
    ByVal destinationFolder As String, _
    ByRef workspaceNameCopy As IWorkspaceName _
) As Boolean
public bool Copy (
    IWorkspaceName WorkspaceName,
    string destinationFolder,
    ref IWorkspaceName workspaceNameCopy
  IWorkspaceName* WorkspaceName,
  BSTR destinationFolder,
  IWorkspaceName** workspaceNameCopy
WorkspaceName [in]

WorkspaceName is a parameter of type IWorkspaceName* destinationFolder [in]
destinationFolder is a parameter of type BSTR workspaceNameCopy [out]
workspaceNameCopy is a parameter of type IWorkspaceName**

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.


The Copy and Move methods can be used to copy or move workspaces or connection files between folders in the file system. The Boolean result indicates if the operation was successful. In the case of remote database workspaces, these operations work on the connection file representing the workspace.

See Also

IWorkspaceFactory Interface