Compatibility:
SharePoint 2013 Foundation (SPF) and Server (SPS) SharePoint 2010 Foundation (SPF) and Server (SPS) Windows SharePoint Services (WSS) 3.0 / Microsoft Office SharePoint Server (MOSS) 2007
SPF & SPS 2013 • 2010 • 2007
User Voices
(Loading...)
« Settings for Export Actions | Configuration Settings »
Saturday
Mar072009

Scheduled Automatic Background Exports

In a future release, ExportZen will offer a full-fledged SharePoint Timer Job integrated into Central Administration for scheduling automated CSV List data exports. Even in the current release however, the software provides a fully workable way for you to start automating and scheduling exports immediately. This involves only a few setup steps outlined in this topic.

Running exports on Windows Server, outside of SharePoint:

When you successfully deployed ExportZen to your SharePoint environment, an executable file ExportZen also got deployed to the file systems of your farm servers. The setup wizard (more specifically, the ExportZen WSP solution package) placed this executable in your "14 hive" (or your "12 hive" on SharePoint 2007), ie. the full executable path is most likely C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\TEMPLATE\LAYOUTS\roxority_ExportZen\ExportZen (or a localized equivalent path — do note, even on SharePoint 2013, ExportZen uses the "14 hive", not the "15 hive").

Once you have defined a CSV export action, this action can also be invoked by the above command-line program. It takes three arguments:

  1. The first argument needs to be "quoted" and specifies the full URL of the List or Document Library to be exported: for example "http://our-sharepoint/projects/Lists/Tasks".
  2. The second argument needs to be "quoted" and specifies the name or ID of your export action. You likely provided the name yourself initially when the export action was set up, if unsure simply look it up on the Export Actions page.
  3. The third argument is also specified in quotation marks and specifies the full path of the exported .CSV file, to be stored directly in the SharePoint web front-end server file system.

Of course, you'll need to run ExportZen at all times:

  • with no more and no less than those three arguments, and
  • under a user account with read access to the List, read access to the 14 hive (or 12 hive) and write access to the specified file system location.

However, other than that you may invoke the tool in any way you wish, and do with its output file as you please.

Use built-in Windows Server features for scheduling:

Once you have experimentally and interactively tested that your export also works with the ExportZen command-line utility too, you can schedule your exports using just the Task Scheduler that's part of Windows Server. (Naturally, the Task Scheduler service needs to auto-run for this.)

Apart from setting the path and arguments to ExportZen as described in the above paragraph, you should make sure the task:

  • will run under the appropriate user account,
  • is set to run regardless of whether that user is logged on interactively or not, and
  • of course, has your desired schedule applied.