Create Excel Files with Python
Create Excel Files with Python
XlsxWriter
Release 1.4.0
John McNamara
1 Introduction 3
i
7.2 worksheet.add_write_handler() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
7.3 worksheet.write_string() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
7.4 worksheet.write_number() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
7.5 worksheet.write_formula() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
7.6 worksheet.write_array_formula() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
7.7 worksheet.write_blank() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
7.8 worksheet.write_boolean() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
7.9 worksheet.write_datetime() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
7.10 worksheet.write_url() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
7.11 worksheet.write_rich_string() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
7.12 worksheet.write_row() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
7.13 worksheet.write_column() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
7.14 worksheet.set_row() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
7.15 worksheet.set_row_pixels() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
7.16 worksheet.set_column() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
7.17 worksheet.set_column_pixels() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
7.18 worksheet.insert_image() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
7.19 worksheet.insert_chart() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
7.20 worksheet.insert_textbox() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
7.21 worksheet.insert_button() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
7.22 worksheet.data_validation() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
7.23 worksheet.conditional_format() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
7.24 worksheet.add_table() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
7.25 worksheet.add_sparkline() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77
7.26 worksheet.write_comment() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79
7.27 worksheet.show_comments() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
7.28 worksheet.set_comments_author() . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
7.29 worksheet.get_name() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
7.30 [Link]() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82
7.31 [Link]() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
7.32 [Link]() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83
7.33 worksheet.set_first_sheet() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
7.34 worksheet.merge_range() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
7.35 [Link]filter() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 87
7.36 worksheet.filter_column() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
7.37 worksheet.filter_column_list() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89
7.38 worksheet.set_selection() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
7.39 worksheet.freeze_panes() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
7.40 worksheet.split_panes() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91
7.41 worksheet.set_zoom() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
7.42 worksheet.right_to_left() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92
7.43 worksheet.hide_zero() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93
7.44 worksheet.set_tab_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93
7.45 [Link]() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94
7.46 worksheet.unprotect_range() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95
7.47 worksheet.set_default_row() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
7.48 worksheet.outline_settings() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
7.49 worksheet.set_vba_name() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
ii
7.50 worksheet.ignore_errors() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 97
iii
9.23 format.set_indent() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138
9.24 format.set_shrink() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139
9.25 format.set_text_justlast() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
9.26 format.set_pattern() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
9.27 format.set_bg_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140
9.28 format.set_fg_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141
9.29 format.set_border() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 141
9.30 format.set_bottom() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142
9.31 format.set_top() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142
9.32 format.set_left() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
9.33 format.set_right() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
9.34 format.set_border_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
9.35 format.set_bottom_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143
9.36 format.set_top_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
9.37 format.set_left_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
9.38 format.set_right_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
9.39 format.set_diag_border() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144
9.40 format.set_diag_type() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145
9.41 format.set_diag_color() . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145
iv
12.1 Exception: XlsxWriterException . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177
12.2 Exception: XlsxFileError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177
12.3 Exception: XlsxInputError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178
12.4 Exception: FileCreateError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178
12.5 Exception: UndefinedImageSize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178
12.6 Exception: UnsupportedImageFormat . . . . . . . . . . . . . . . . . . . . . . . . . . 179
12.7 Exception: FileSizeError . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
12.8 Exception: EmptyChartSeries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180
12.9 Exception: DuplicateTableName . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
12.10Exception: InvalidWorksheetName . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181
12.11Exception: DuplicateWorksheetName . . . . . . . . . . . . . . . . . . . . . . . . . . 182
v
18.10Chart Formatting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247
18.11Chart formatting: Line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 248
18.12Chart formatting: Border . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 251
18.13Chart formatting: Solid Fill . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 251
18.14Chart formatting: Pattern Fill . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253
18.15Chart formatting: Gradient Fill . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 256
18.16Chart Fonts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 258
18.17Chart Layout . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260
18.18Date Category Axes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262
18.19Chart Secondary Axes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262
18.20Combined Charts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264
18.21Chartsheets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266
18.22Charts from Worksheet Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267
18.23Chart Limitations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
18.24Chart Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268
vi
23.10name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328
23.11total_row . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329
23.12columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329
23.13Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334
vii
29.1 The Excel XLSM file format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 371
29.2 How VBA macros are included in XlsxWriter . . . . . . . . . . . . . . . . . . . . . . 372
29.3 The vba_extract.py utility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 372
29.4 Adding the VBA macros to a XlsxWriter file . . . . . . . . . . . . . . . . . . . . . . . 372
29.5 Setting the VBA codenames . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 373
29.6 What to do if it doesn’t work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374
31 Examples 389
31.1 Example: Hello World . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 389
31.2 Example: Simple Feature Demonstration . . . . . . . . . . . . . . . . . . . . . . . . 390
31.3 Example: Catch exception on closing . . . . . . . . . . . . . . . . . . . . . . . . . . 391
31.4 Example: Dates and Times in Excel . . . . . . . . . . . . . . . . . . . . . . . . . . . 392
31.5 Example: Adding hyperlinks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 394
31.6 Example: Array formulas . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 396
31.7 Example: Applying Autofilters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 397
31.8 Example: Data Validation and Drop Down Lists . . . . . . . . . . . . . . . . . . . . . 403
31.9 Example: Conditional Formatting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 407
31.10Example: Defined names/Named ranges . . . . . . . . . . . . . . . . . . . . . . . . 414
31.11Example: Merging Cells . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 416
31.12Example: Writing “Rich” strings with multiple formats . . . . . . . . . . . . . . . . . 417
31.13Example: Merging Cells with a Rich String . . . . . . . . . . . . . . . . . . . . . . . 419
31.14Example: Inserting images into a worksheet . . . . . . . . . . . . . . . . . . . . . . 421
31.15Example: Inserting images from a URL or byte stream into a worksheet . . . . . . . 423
31.16Example: Left to Right worksheets and text . . . . . . . . . . . . . . . . . . . . . . . 425
31.17Example: Simple Django class . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426
31.18Example: Simple HTTP Server (Python 2) . . . . . . . . . . . . . . . . . . . . . . . 427
31.19Example: Simple HTTP Server (Python 3) . . . . . . . . . . . . . . . . . . . . . . . 429
31.20Example: Adding Headers and Footers to Worksheets . . . . . . . . . . . . . . . . 430
31.21Example: Freeze Panes and Split Panes . . . . . . . . . . . . . . . . . . . . . . . . 434
31.22Example: Worksheet Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 436
31.23Example: Writing User Defined Types (1) . . . . . . . . . . . . . . . . . . . . . . . . 444
31.24Example: Writing User Defined Types (2) . . . . . . . . . . . . . . . . . . . . . . . . 446
31.25Example: Writing User Defined types (3) . . . . . . . . . . . . . . . . . . . . . . . . 448
31.26Example: Ignoring Worksheet errors and warnings . . . . . . . . . . . . . . . . . . . 450
viii
31.27Example: Sparklines (Simple) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 452
31.28Example: Sparklines (Advanced) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 453
31.29Example: Adding Cell Comments to Worksheets (Simple) . . . . . . . . . . . . . . . 460
31.30Example: Adding Cell Comments to Worksheets (Advanced) . . . . . . . . . . . . . 462
31.31Example: Insert Textboxes into a Worksheet . . . . . . . . . . . . . . . . . . . . . . 467
31.32Example: Outline and Grouping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 472
31.33Example: Collapsed Outline and Grouping . . . . . . . . . . . . . . . . . . . . . . . 477
31.34Example: Setting Document Properties . . . . . . . . . . . . . . . . . . . . . . . . . 481
31.35Example: Simple Unicode with Python 2 . . . . . . . . . . . . . . . . . . . . . . . . 483
31.36Example: Simple Unicode with Python 3 . . . . . . . . . . . . . . . . . . . . . . . . 484
31.37Example: Unicode - Polish in UTF-8 . . . . . . . . . . . . . . . . . . . . . . . . . . . 484
31.38Example: Unicode - Shift JIS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 486
31.39Example: Setting Worksheet Tab Colors . . . . . . . . . . . . . . . . . . . . . . . . 488
31.40Example: Diagonal borders in cells . . . . . . . . . . . . . . . . . . . . . . . . . . . 489
31.41Example: Enabling Cell protection in Worksheets . . . . . . . . . . . . . . . . . . . 491
31.42Example: Hiding Worksheets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 492
31.43Example: Hiding Rows and Columns . . . . . . . . . . . . . . . . . . . . . . . . . . 494
31.44Example: Example of subclassing the Workbook and Worksheet classes . . . . . . 495
31.45Example: Advanced example of subclassing . . . . . . . . . . . . . . . . . . . . . . 497
31.46Example: Adding a VBA macro to a Workbook . . . . . . . . . . . . . . . . . . . . . 501
ix
33.2 Example: Pandas Excel with multiple dataframes . . . . . . . . . . . . . . . . . . . 579
33.3 Example: Pandas Excel dataframe positioning . . . . . . . . . . . . . . . . . . . . . 580
33.4 Example: Pandas Excel output with a chart . . . . . . . . . . . . . . . . . . . . . . . 581
33.5 Example: Pandas Excel output with conditional formatting . . . . . . . . . . . . . . 583
33.6 Example: Pandas Excel output with an autofilter . . . . . . . . . . . . . . . . . . . . 584
33.7 Example: Pandas Excel output with a worksheet table . . . . . . . . . . . . . . . . . 586
33.8 Example: Pandas Excel output with datetimes . . . . . . . . . . . . . . . . . . . . . 588
33.9 Example: Pandas Excel output with column formatting . . . . . . . . . . . . . . . . 590
33.10Example: Pandas Excel output with user defined header format . . . . . . . . . . . 592
33.11Example: Pandas Excel output with a line chart . . . . . . . . . . . . . . . . . . . . 593
33.12Example: Pandas Excel output with a column chart . . . . . . . . . . . . . . . . . . 595
x
39.3 Release 1.3.8 - March 29 2021 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 607
39.4 Release 1.3.7 - October 13 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 608
39.5 Release 1.3.6 - September 23 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . 608
39.6 Release 1.3.5 - September 21 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . 608
39.7 Release 1.3.4 - September 16 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
39.8 Release 1.3.3 - August 13 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
39.9 Release 1.3.2 - August 6 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
39.10Release 1.3.1 - August 3 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
39.11Release 1.3.0 - July 30 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
39.12Release 1.2.9 - May 29 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
39.13Release 1.2.8 - February 22 2020 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 609
39.14Release 1.2.7 - December 23 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . 610
39.15Release 1.2.6 - November 15 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . 610
39.16Release 1.2.5 - November 10 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . 610
39.17Release 1.2.4 - November 9 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 610
39.18Release 1.2.3 - November 7 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 610
39.19Release 1.2.2 - October 16 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
39.20Release 1.2.1 - September 14 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
39.21Release 1.2.0 - August 26 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
39.22Release 1.1.9 - August 19 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
39.23Release 1.1.8 - May 5 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
39.24Release 1.1.7 - April 20 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611
39.25Release 1.1.6 - April 7 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 612
39.26Release 1.1.5 - February 22 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 612
39.27Release 1.1.4 - February 10 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 612
39.28Release 1.1.3 - February 9 2019 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 612
39.29Release 1.1.2 - October 20 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 612
39.30Release 1.1.1 - September 22 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
39.31Release 1.1.0 - September 2 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
39.32Release 1.0.9 - August 27 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
39.33Release 1.0.8 - August 27 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
39.34Release 1.0.7 - August 16 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
39.35Release 1.0.6 - August 15 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613
39.36Release 1.0.5 - May 19 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 614
39.37Release 1.0.4 - April 14 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 614
39.38Release 1.0.3 - April 10 2018 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 614
39.39Release 1.0.2 - October 14 2017 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 614
39.40Release 1.0.1 - October 14 2017 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 614
39.41Release 1.0.0 - September 16 2017 . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
39.42Release 0.9.9 - September 5 2017 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
39.43Release 0.9.8 - July 1 2017 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
39.44Release 0.9.7 - June 25 2017 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
39.45Release 0.9.6 - Dec 26 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
39.46Release 0.9.5 - Dec 24 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
39.47Release 0.9.4 - Dec 2 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 615
39.48Release 0.9.3 - July 8 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
39.49Release 0.9.2 - June 13 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
39.50Release 0.9.1 - June 8 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
xi
39.51Release 0.9.0 - June 7 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
39.52Release 0.8.9 - June 1 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
39.53Release 0.8.8 - May 31 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
39.54Release 0.8.7 - May 13 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 616
39.55Release 0.8.6 - April 27 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.56Release 0.8.5 - April 17 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.57Release 0.8.4 - January 16 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.58Release 0.8.3 - January 14 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.59Release 0.8.2 - January 13 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.60Release 0.8.1 - January 12 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.61Release 0.8.0 - January 10 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.62Release 0.7.9 - January 9 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 617
39.63Release 0.7.8 - January 6 2016 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
39.64Release 0.7.7 - October 19 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
39.65Release 0.7.6 - October 7 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
39.66Release 0.7.5 - October 4 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
39.67Release 0.7.4 - September 29 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
39.68Release 0.7.3 - May 7 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
39.69Release 0.7.2 - March 29 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 618
39.70Release 0.7.1 - March 23 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
39.71Release 0.7.0 - March 21 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
39.72Release 0.6.9 - March 19 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
39.73Release 0.6.8 - March 17 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
39.74Release 0.6.7 - March 1 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
39.75Release 0.6.6 - January 16 2015 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 619
39.76Release 0.6.5 - December 31 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
39.77Release 0.6.4 - November 15 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
39.78Release 0.6.3 - November 6 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
39.79Release 0.6.2 - November 1 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
39.80Release 0.6.1 - October 29 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 620
39.81Release 0.6.0 - October 15 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
39.82Release 0.5.9 - October 11 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
39.83Release 0.5.8 - September 28 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
39.84Release 0.5.7 - August 13 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
39.85Release 0.5.6 - July 22 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 621
39.86Release 0.5.5 - May 6 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 622
39.87Release 0.5.4 - May 4 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 622
39.88Release 0.5.3 - February 20 2014 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 622
39.89Release 0.5.2 - December 31 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . 622
39.90Release 0.5.1 - December 2 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 622
39.91Release 0.5.0 - November 17 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . 623
39.92Release 0.4.9 - November 17 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . 623
39.93Release 0.4.8 - November 13 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . 623
39.94Release 0.4.7 - November 9 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 623
39.95Release 0.4.6 - October 23 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 623
39.96Release 0.4.5 - October 21 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 623
39.97Release 0.4.4 - October 16 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
39.98Release 0.4.3 - September 12 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
xii
39.99Release 0.4.2 - August 30 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
39.100Release 0.4.1 - August 28 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
39.101Release 0.4.0 - August 26 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
39.102Release 0.3.9 - August 24 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
39.103Release 0.3.8 - August 23 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 624
39.104Release 0.3.7 - August 16 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 625
39.105Release 0.3.6 - July 26 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 625
39.106Release 0.3.5 - June 28 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 625
39.107Release 0.3.4 - June 27 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 625
39.108Release 0.3.3 - June 10 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 625
39.109Release 0.3.2 - May 1 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 626
39.110Release 0.3.1 - April 27 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 626
39.111Release 0.3.0 - April 7 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 626
39.112Release 0.2.9 - April 7 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 626
39.113Release 0.2.8 - April 4 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 626
39.114Release 0.2.7 - April 3 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
39.115Release 0.2.6 - April 1 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
39.116Release 0.2.5 - April 1 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
39.117Release 0.2.4 - March 31 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
39.118Release 0.2.3 - March 27 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
39.119Release 0.2.2 - March 27 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 627
39.120Release 0.2.1 - March 25 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
39.121Release 0.2.0 - March 24 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
39.122Release 0.1.9 - March 19 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
39.123Release 0.1.8 - March 18 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
39.124Release 0.1.7 - March 18 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
39.125Release 0.1.6 - March 17 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 628
39.126Release 0.1.5 - March 10 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 629
39.127Release 0.1.4 - March 8 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 629
39.128Release 0.1.3 - March 7 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 629
39.129Release 0.1.2 - March 6 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 629
39.130Release 0.1.1 - March 3 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 629
39.131Release 0.1.0 - February 28 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 629
39.132Release 0.0.9 - February 27 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 630
39.133Release 0.0.8 - February 26 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 630
39.134Release 0.0.7 - February 25 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 630
39.135Release 0.0.6 - February 22 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 631
39.136Release 0.0.5 - February 21 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 631
39.137Release 0.0.4 - February 20 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 631
39.138Release 0.0.3 - February 19 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 631
39.139Release 0.0.2 - February 18 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 631
39.140Release 0.0.1 - February 17 2013 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 632
40 Author 633
40.1 Asking questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 633
40.2 Sponsorship and Donations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 633
41 License 635
xiii
xiv
The iterative release history described in Sources 4 and 5 reveals development trends that include incremental improvements, feature updates, and bug fixes aimed at refining user experience and adapting to new technological environments. The frequent releases with detailed notes suggest a responsive development process prioritizing stability, performance, and user-requested features, indicating a commitment to continuous enhancement and adaptation to the evolving needs of its user base .
worksheet.unprotect_range() improves data security by allowing specific ranges to be editable while maintaining protection over the rest of the worksheet, facilitating controlled data entry in complex spreadsheets. However, its limitations include the potential for user errors or unauthorized access if permissions are not carefully managed, as it relies on detailed settings configurations to ensure that only intended cells are editable .
The function worksheet.set_vba_name() plays a crucial role in integrating spreadsheets with VBA (Visual Basic for Applications) by assigning a unique name that can be referenced in VBA scripts. This allows advanced users to control and manipulate spreadsheet behaviors programmatically, opening up applications such as automated data processing, complex calculations, custom data validation, and personalized interactivity within the spreadsheet, enhancing productivity and the scope of spreadsheet functionalities .
worksheet.set_tab_color() enhances user interaction by allowing the differentiation of worksheet tabs through color coding, improving visual organization and making navigation between sheets more intuitive. Practical applications include categorizing worksheets by type or function, highlighting specific worksheets frequently used, and enhancing readability and quick retrieval of data in complex workbooks .
Both worksheet.set_landscape() and worksheet.set_portrait() define the orientation of printed spreadsheets, but their use depends on the dataset's layout. set_landscape() is preferable for wide datasets, allowing more columns to fit on a single page, enhancing readability for horizontally extensive data. set_portrait(), on the other hand, suits datasets longer than they are wide, fitting more rows and reducing the number of pages. Choosing the appropriate orientation optimizes space and legibility in printouts .
worksheet.repeat_rows() and worksheet.repeat_columns() are used to repeatedly print specific rows or columns on each page of a printed spreadsheet report. This ensures that essential data headers or labeling remain visible, improving readability and comprehension across multiple pages. They are particularly useful in lengthy datasets or reports where understanding the context and headings on each printed page is crucial for data analysis or presentation .
The release of version 0.5.0 introduced changes that typically reflect adjustments and enhancements based on user feedback or technical advancements made since previous versions. These might include the addition of new features, bug fixes, or performance improvements tailored to ease of use and efficiency. Tracking these changes highlights the software's evolution in response to user needs and technological trends, ensuring continued relevance and functionality .
The use of worksheet.set_zoom() is beneficial in scenarios where adjusting the view size of the spreadsheet is needed to fit more data into the visible screen area or to focus on detailed information by enlarging it. This feature is especially useful when presenting data to an audience or when working with extensive datasets. However, potential drawbacks include possible distortion of the visual layout when excessively zoomed in or out, and performance issues if the scaling is not optimal for the data's presentation .
The function worksheet.write_formula() allows users to write a single formula into a worksheet cell, providing a straightforward way to perform calculations within spreadsheets. In contrast, worksheet.write_array_formula() writes an array formula that applies to multiple cells based on a defined range, enabling more complex data processing and analysis by applying a single formula across an entire array or a set of data points .
The function worksheet.hide_gridlines() is utilized to remove the default cell boundaries in a spreadsheet, creating a cleaner and more polished appearance that emphasizes the content over the structure. It is particularly effective for presentations or reports where a professional look is desired. While it enhances aesthetics, the absence of gridlines may make it harder to track and align data, potentially hindering data entry precision .