Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 11810
  • Last Modified:

Excel 2007 (xlsx) Create New WorkSheet in C#

I'm using the SpreadsheetDocument object to create a spreadsheet, and everything is working fine.  The only stumbling block I'm having is I can't seem to create new Worksheets.  I can retrieve a list of all worksheets in the system using XPath, but as my XML skills are limited, I'd like some pointers on how to create new Sheets in the Workbook from scratch.

Gracias.
0
tradeline
Asked:
tradeline
  • 3
1 Solution
 
Daniel JungesCommented:
0
 
tradelineAuthor Commented:
Thanks junges, but I've already incorporated most of the code I need using the Microsoft.Office.DocumentFormat.OpenXml.Packing assembly, and adding new worksheets are the only thing that's missing.

I was hoping to leverage the same assembly and code structure.

sk
0
 
tradelineAuthor Commented:
Ended up converting to the open source version.  There are a few bugs in the code, but they're documented on codeplex and it's a much simpler facade.  Thanks.
0
 
tradelineAuthor Commented:
For future reference, and people searching this solution, DO NOT use the CodePlex ExcelPackage.  Use (Microsoft.Office.DocumentFormat.OpenXml.Packaging) instead.

The CodePlex library (as of Dec 2007) is incredibly buggy.  Half the functions aren't implemented, and there are several major bugs left unfixed.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now