This content is for v4.x (Alpha). Switch to the Stable version.
Excel
The Excel class/struct, an integral part of the library, facilitates seamless interaction with Excel workbooks. Designed to simplify the creation and manipulation of Excel (.xlsx) files, this class/struct provides a user-friendly interface for developers to efficiently handle data, worksheets, and formatting.
Key Features
- Effortless Initialization: Initializing a new Excel workbook is simplified with the
Excelclass/struct. Developers can swiftly create new workbooks or open existing ones, setting the stage for easy data management. - Worksheet Manipulation: The class/struct offers intuitive methods for adding, deleting, and manipulating worksheets within a workbook. Developers can efficiently organize data and structure it across multiple sheets.
- Cell-Level Operations: Granular control over individual cells is provided, allowing developers to set values, apply formatting, and perform various operations on specific cells within a worksheet.
- Data Import and Export: The
Excelclass/struct supports seamless data import from external sources and export to various formats. This enables efficient integration with external data sets and applications.
Basic Code Samples
let mut file = crate::spreadsheet_2007::Excel::new( None, crate::spreadsheet_2007::ExcelPropertiesModel::default(), ).expect("File Created Failed");// Add Sheet with custom namefile.add_sheet_mut(Some("Test".to_string())) .expect("Failed to add static Sheet");// Add Sheet with default namefile.add_sheet_mut(None) .expect("Failed to add static Sheet");// Save the result filefile.save_as(&get_save_file(None)) .expect("File Save Failed");Excel excel = new Excel();Worksheet worksheet = excel.AddSheet();excel.SaveAs(string.Format("../../test-{0}.xlsx", DateTime.Now.ToString("yyyy-MM-dd-HH-mm-ss")));TODO
Phase 2
Phase 2
Phase 2