The official name: 2007 Microsoft® Office system
Finally, I am able to spell the real name for the next version of Office: 2007 Microsoft® Office system.
For those of you who have not seen the press passes and want to catch-up here is a list with some of them:
- FAQ: Looking into Office 12
- Does "Office 12" equal Office 2007?
- Microsoft announces Office 2007 pricing, details
See the 2007 Microsoft Office System Pricing and the 2007 Microsoft Office System Packaging.
Maybe you have heard that this is the biggest release of the decade, and I can tell you that this version of Office has great potential as a development platform. Lots of features/enhancements were announced on Beta 1 and for Beta 2 there are more cool surprises waiting to be announced.
My latest experiment with 2007 Microsoft® Office :) is exporting an ASP.NET 2.0 GridView to Excel 2007. If you use the following code snippet, you will be able to export the content of a SqlDataSource (used to DataBind a GridView) to Excel (without automation):
protected void ExportToExcel() {
Response.Clear();
Response.Buffer = true;
Response.ContentType = "application/vnd.ms-excel";
Response.Charset = "";
this.EnableViewState = false;
System.IO.StringWriter sw = new System.IO.StringWriter();
System.Web.UI.HtmlTextWriter htw = new System.Web.UI.HtmlTextWriter(sw);
GridView grid = new GridView();
grid.DataSource = SqlDataSource1.Select(DataSourceSelectArguments.Empty);
grid.AutoGenerateColumns = true;
grid.DataBind();
grid.RenderControl(htw);
Response.Write(sw.ToString());
Response.End();
}
We built a Web based application for MSDN content management, and we export reports to Excel 2003 using the previous snippet of code. One thing that we don't like is that we lose all formatting, so we have the data, but then we have to make it pretty again.
I ran the same process on a machine where I have the last build of 2007 Microsoft® Office and Excel 2007 is smart enough to keep my formatting. Another cool enhancement. For those of you who have Beta 1, please give it a try.
Comments
Anonymous
February 16, 2006
Well, not quite "Office 2007" -- "2007 Microsoft Office System." Whoever decided to put the 2007 first should get a stern talking-to.Anonymous
February 21, 2006
Hi All,
I had to edit this blog entry to comply with the naming conventions. So here's the thing:
As a system, the real name is 2007 Microsoft® Office system.
The suite product names are: Microsoft® Office <Edition> 2007. See the 2007 Microsoft Office System Packaging.
Finally, each program can be called <Program> 2007.
For more details see:
http://www.microsoft.com/office/preview/suites.mspxAnonymous
December 18, 2006
This still doesnt work for me. It worked in Excel 97 but in Excel 2007 I keep getting the error The file you are trying to open, <filename>, is in a different format than specified by the file extension. Verify that the file is not corrupted and is from a trusted source before opening the file. Do you want to open the file now? <Yes> <No> <help> The only difference in code is that - I was also doing Response.AddHeader("content-disposition", "attachment;filename=somename.xls");Anonymous
March 21, 2007
Hi, I an experiencing the same problem... It looks like Office 2007 issue (doesn't seem to me to be fixed :-() http://office.microsoft.com/en-us/products/FX101517941033.aspxAnonymous
April 18, 2007
http://office.microsoft.com/en-us/products/FX101633871033.aspx#9 Looks like this will not be fixed in the final release version.Anonymous
September 30, 2007
The comment has been removedAnonymous
January 22, 2008
Rename the export file to .xlsx and your problem is solved. SandeepAnonymous
February 22, 2008
But I don't know whether my clients will have Office 2003 or Office 2007 installed. If I just name the file ".xlsx" then my downloads won't work for many clients. Is there any way to have the client machine check which verison of MS Office is opening up and determine the file extension on the fly based on that?Anonymous
January 26, 2010
I'm with Shira. That's not much help at all.