A while ago I talked about how to extract all the WSPs in a SharePoint Farm as you can see in this article. After reviewing again this article, I noted that the way I used there to extract the WSPs didn’t work right for SharePoint 2013. Fortunately, I quickly found another approach to extract all the WSPs and this is what I’m sharing tin this article. AS you can see, using the server side API you can easily access to the collection of farm solutions using a SPSolutionCollection object and simply iterate through it in order to save each .WSP.
As a result you will get:
- On the one hand, you will see all the solutions extracted in the output window.
- On the other hand, you will have all the solutions physical saved in the server drive.