Pages

Thursday, March 8, 2012

How to Copy a SharePoint List or Document Library to Another Site?

You may need to copy a SharePoint list across site collections or sub-sites for various purposes. This can be done using STSADM following these steps:

STEP 1: Backup Your Target and Source Site

Make sure to backup your target and source sites. You can use STSADM backup operation for this purpose.

image

An example of the command would be:

stsadm -o backup -url http://yoursite -filename c:\yoursitebackup.bak

STEP 2: EXPORT LIST OR DOCUMENT LIBRARY


Export the list using STSADM Export operation. The syntax is provided below:

image


An example of the command would be:



stsadm -o Export -url http://yoursite/doclibrary -filename C:\doclibrary.bak -includesecurity


Note: On SharePoint 2010, you can export a list from central administration if needed. The Central Administration interface, however, does not provide an option to import the library.


STEP 3: IMPORT LIST OR DOCUMENT LIBRARY TO THE TARGET SITE


Import the list using STSADM Import operation. The syntax is provided below:


image



stsadm -o import -url http://yoursite2/doclibrary -includeusersecurity -activatesolution

Hope it helps!

No comments:

Post a Comment