By adding some flavor with an automation mechanism, this technique could be very useful to the scenarios wherein we need to download documents in bulk on a schedule based job.
In order to setup this demo, I have created a document library in my SharePoint Online Site. Though this is equally applicable to On Premise implementations of SharePoint.
I have added a new document library in the SharePoint Online Site with the name “Prashant Documents” and uploaded a set of documents to it.

I have also set up a local folder on the disk drive which will act as a destination folder for the files to be downloaded.

Step 1- Initiate the Client Context
In order to get more information on Setting up Client Context and other Environmental Configurations, you may visit one of the earlier articles SharePoint Online: How to Install SharePoint Online Management Shell.

Step 2
Instantiate and load SharePoint Document Library Object.





Join the conversation! Your thoughts help the community grow.