Using PowerShell to Checkout and Checkin a file generated from a report...
-
Friday, January 07, 2011 3:13 PMI have a excel file that is being generated from a PowerShell script for reporting purposes. I would like to have the end result be saved to a SharePoint 2007 or SharePoint 2010 site in a Documents Library. On this location I plan to have versioning so, I believe, that I have to Checkout the Excel document, Open it, do my editing with the powershell script and then have it CheckIn and close it. I have been unable to find a working solution to this so far. Anyone have some PowerShell code to checkout an excel file, do whatever, and then check it back in with the same name? Thanks
Answers
-
Friday, January 07, 2011 3:53 PM
These two scripts wil work for you.
http://sharepointandpowershell.com/wp-content/uploads/Invoke-SPFileCheckin.txt
http://sharepointandpowershell.com/wp-content/uploads/Invoke-SPFileCheckout.txt
Hope this helps
Liam
- Marked As Answer by Wayne FanModerator Wednesday, January 12, 2011 1:51 AM
All Replies
-
Friday, January 07, 2011 3:53 PM
These two scripts wil work for you.
http://sharepointandpowershell.com/wp-content/uploads/Invoke-SPFileCheckin.txt
http://sharepointandpowershell.com/wp-content/uploads/Invoke-SPFileCheckout.txt
Hope this helps
Liam
- Marked As Answer by Wayne FanModerator Wednesday, January 12, 2011 1:51 AM
-
Wednesday, March 07, 2012 11:15 AM
Hi
URL's appear to be broken
-
14 hours 4 minutes ago
Hi Liam,
The filenames seem like those are exactly what I need. But the links are broken. :(
Shawn Keene

