Saturday, March 9, 2013

Easy way to download or copy list attachments to document library in SharePoint


The steps how to get SharePoint list attachments copied to a document library (or in general, just get the list attachments to a local folder).
Business problem: A SharePoint user (not a developer) wants to take attachments collected in a list and store them in a local folder or upload them to a document library:
  1. In Windows Explorer, go to My Network Places > Add Network Place
  2. In the “Add Network Place” Wizard, click next and select “Choose another network location”, click next
  3. Type in the url of the Sharepoint site that contains the list (I assume you have admin rights on that sharepoint site), e.g., http://intranetname/topics/projects/sitename
  4. Click on your newly created network location in Windows Explorer. This should give you a folder view of your SharePoint site.
  5. Select the folder “Lists” > and find your list name. Within your list folder there will be an attachments folder.
  6. You will notice that the attachments for each list item are stored in individual folders (we will remedy that in a second).
  7. Copy all folders to your local drive in an empty folder like attachtemp.
  8. To get the folders out of their subfolders, simply do a search for all the file types you have in them (in my case I was simply looking for *.doc*). The search will list all the found files in a flat view. Now you can copy them out of your search window to where you need them. Since I wanted to upload them to another SharePoint library, I simply copied them into the root of attachtemp.
  9. Go to your target SharePoint library and upload all files (Note: If you have hundreds of documents, make sure to temporarily disable “require file check-out” so that you don’t have all files checked out to you after uploading. Once done, set the library back to require check-out if applicable.
  10. Done, yeah!

Taking list item back up with attachments

Sometimes we require taking back up of list items along with attachments. Definitely there is an option to export to excel, however that doesn’t copy attachment with it and hence it is a drawback only if you want attachment with list item as well, else export to excel is really a cool functionality.

Coming back to the point, so what do we do to get the attachment as well? Well, the answer to this question lies in the same menu and that option is Open with Access.

So go ahead with your list items that you want to back up. Open the Actions menu and click on open with Access.




Specify a new location for your database and also chose whether you want to be connected with SharePoint list so that any changes can be reflected here and also vice versa, or just you want to have a copy of it which is export the data.



That’s it. You have just taken a back up of your list items with attachments. 

No comments:

Post a Comment