Excel::_WorkbookPtr::SaveAs(..) - how to save as ".xlsx" type office 2007 fomat.?

Trips

Well-known member
Joined
Aug 7, 2010
Messages
2,788
My app will save work book as ".xls" type., i use  the below method.. <br/>hResult = m_pWorkBook->SaveAs(_bstr_t(bstrFileName), <br/>              &vtFileFormat,   // FileFormat <br/>         &vtMissing,    // Password<br/>         &vtMissing,    // WriteResPassword<br/>         &vtMissing,    // ReadOnlyRecommended<br/>         &vtMissing,    // CreateBackup<br/>         Excel::xlNoChange);   // AccessMode<br/><br/>If i want to save it as ".xlsx" type ie,. office 2007 type excel, wat is file format (second)parameter i should pass, else if it has any other api to be used..? <br/><br/>All the other creation/data transfer to excel are done in the way that has to be done for .xls (office 2003) type. whether my objective in saving <br/>".xlsx" type is correct, else i should change everything..!?<br/><br/>Thanks in advance..<br/>M.Mahesh.

View the full article
 
Back
Top