The class CWorkbook is used to manage creation, population and saving .xlsx files.
More...
#include <Workbook.h>
Public Member Functions |
| CWorkbook () |
| The class default constructor.
|
virtual | ~CWorkbook () |
| The class destructor.
|
CWorksheet & | AddSheet (const _tstring &title) |
| Adds another data sheet into the workbook.
|
CWorksheet & | AddSheet (const _tstring &title, std::vector< ColumnWidth > &colWidths) |
| Adds another data sheet into the workbook.
|
CWorksheet & | AddSheet (const _tstring &title, uint32_t frozenWidth, uint32_t frozenHeight) |
| Adds another data sheet with a frozen pane into the workbook.
|
CWorksheet & | AddSheet (const _tstring &title, uint32_t frozenWidth, uint32_t frozenHeight, std::vector< ColumnWidth > &colWidths) |
| Adds another data sheet with a frozen pane into the workbook.
|
CChartsheet & | AddChart (const _tstring &title) |
| Adds another chart into the workbook.
|
CChartsheet & | AddChart (const _tstring &title, EChartTypes type) |
| Adds another chart into the workbook.
|
bool | Save (const _tstring &name) |
| Saves workbook into the specified file.
|
Detailed Description
The class CWorkbook is used to manage creation, population and saving .xlsx files.
Constructor & Destructor Documentation
SimpleXlsx::CWorkbook::CWorkbook |
( |
| ) |
|
The class default constructor.
- Returns
- no
SimpleXlsx::CWorkbook::~CWorkbook |
( |
| ) |
|
|
virtual |
The class destructor.
- Returns
- no
Member Function Documentation
void SimpleXlsx::CWorkbook::AddBorder |
( |
xmlw::XmlStream & |
stream, |
|
|
const TCHAR * |
borderName, |
|
|
Border::BorderItem |
border |
|
) |
| const |
|
private |
Appends border item section into borders set.
- Parameters
-
stream | reference to xml stream |
borderName | border name |
border | style set |
- Returns
- no
void SimpleXlsx::CWorkbook::AddBorders |
( |
xmlw::XmlStream & |
stream | ) |
const |
|
private |
Appends borders section into styles file.
- Parameters
-
stream | reference to xml stream |
- Returns
- no
CChartsheet & SimpleXlsx::CWorkbook::AddChart |
( |
const _tstring & |
title | ) |
|
Adds another chart into the workbook.
- Parameters
-
- Returns
- Reference to a newly created object
Adds another chart into the workbook.
- Parameters
-
title | chart page title |
type | type of main chart |
- Returns
- Reference to a newly created object
void SimpleXlsx::CWorkbook::AddComment |
( |
xmlw::XmlStream & |
xml_stream, |
|
|
const Comment & |
comment |
|
) |
| const |
|
private |
...
- Parameters
-
stream | reference to xml stream |
comments | comment list on the sheet |
- Returns
- Boolean result of the operation
void SimpleXlsx::CWorkbook::AddCommentDrawing |
( |
xmlw::XmlStream & |
xml_stream, |
|
|
const Comment & |
comment |
|
) |
| const |
|
private |
...
- Parameters
-
stream | reference to xml stream |
comments | comment list on the sheet |
- Returns
- Boolean result of the operation
void SimpleXlsx::CWorkbook::AddFills |
( |
xmlw::XmlStream & |
stream | ) |
const |
|
private |
Appends fills section into styles file.
- Parameters
-
stream | reference to xml stream |
- Returns
- no
void SimpleXlsx::CWorkbook::AddFonts |
( |
xmlw::XmlStream & |
stream | ) |
const |
|
private |
Appends fonts section into styles file.
- Parameters
-
stream | reference to xml stream |
- Returns
- no
void SimpleXlsx::CWorkbook::AddNumberFormats |
( |
xmlw::XmlStream & |
stream | ) |
const |
|
private |
Appends number format section into styles file.
- Parameters
-
stream | reference to xml stream |
- Returns
- no
CWorksheet & SimpleXlsx::CWorkbook::AddSheet |
( |
const _tstring & |
title | ) |
|
Adds another data sheet into the workbook.
- Parameters
-
- Returns
- Reference to a newly created object
CWorksheet & SimpleXlsx::CWorkbook::AddSheet |
( |
const _tstring & |
title, |
|
|
std::vector< ColumnWidth > & |
colWidths |
|
) |
| |
Adds another data sheet into the workbook.
- Parameters
-
title | chart page title |
colWidths | list of pairs colNumber:Width |
- Returns
- Reference to a newly created object
CWorksheet & SimpleXlsx::CWorkbook::AddSheet |
( |
const _tstring & |
title, |
|
|
uint32_t |
frozenWidth, |
|
|
uint32_t |
frozenHeight |
|
) |
| |
Adds another data sheet with a frozen pane into the workbook.
- Parameters
-
title | chart page title |
frozenWidth | frozen pane width (in number of cells from 0) |
frozenHeight | frozen pane height (in number of cells from 0) |
- Returns
- Reference to a newly created object
CWorksheet & SimpleXlsx::CWorkbook::AddSheet |
( |
const _tstring & |
title, |
|
|
uint32_t |
frozenWidth, |
|
|
uint32_t |
frozenHeight, |
|
|
std::vector< ColumnWidth > & |
colWidths |
|
) |
| |
Adds another data sheet with a frozen pane into the workbook.
- Parameters
-
title | chart page title |
frozenWidth | frozen pane width (in number of cells from 0) |
frozenHeight | frozen pane height (in number of cells from 0) |
colWidths | list of pairs colNumber:Width |
- Returns
- Reference to a newly created object
void SimpleXlsx::CWorkbook::ClearTemp |
( |
| ) |
|
|
private |
Deletes all temporary files and directories which have been created.
- Returns
- no
Converts numeric format color into its string representation.
- Parameters
-
- Returns
- String color code
_tstring SimpleXlsx::CWorkbook::GetFormatCodeString |
( |
const NumFormat & |
fmt | ) |
|
|
staticprivate |
Converts numeric format object into its string representation.
- Parameters
-
fmt | reference to format to be converted |
- Returns
- String format code
bool SimpleXlsx::CWorkbook::Save |
( |
const _tstring & |
name | ) |
|
Saves workbook into the specified file.
- Parameters
-
name | full path to the file |
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveApp |
( |
| ) |
const |
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveChain |
( |
| ) |
|
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveCommentList |
( |
std::vector< Comment * > & |
comments | ) |
|
|
private |
...
- Parameters
-
comments | comment list on the sheet |
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveComments |
( |
| ) |
|
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveContentType |
( |
| ) |
|
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveCore |
( |
| ) |
const |
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveSharedStrings |
( |
| ) |
|
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveStyles |
( |
| ) |
const |
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveTheme |
( |
| ) |
const |
|
private |
...
- Returns
- Boolean result of the operation
bool SimpleXlsx::CWorkbook::SaveWorkbook |
( |
| ) |
const |
|
private |
...
- Returns
- Boolean result of the operation
The documentation for this class was generated from the following files: