title: Create PivotTable programmatically
body: <p>Using C# and OWC 11.0, I need to create an Excel output with all Raw Data in one sheet then, using that data as the connection string, create pivot tables in another worksheet. This Excel sheet will be downloaded by the end user so they can change parameters in the pivot table and get the report they need. Whenever the raw data is updated, the user will come to dashboard and get the new Excel generated.  </p>
  
  <p>I have the code for getting all the data into the data sheet. How might I set about creating the pivot table on the second work sheet?</p>