xlsx

Create, edit, and validate Excel spreadsheets with formulas using openpyxl and pandas.

1|Updated Jul 2, 2026
One-click install
npx skills add https://github.com/mccleod1290/bb-agentic-setupv2 --skill xlsx-mccleod1290
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: xlsx
Source: https://github.com/mccleod1290/bb-agentic-setupv2/tree/main/documenting-skills/xlsx
Command: npx skills add https://github.com/mccleod1290/bb-agentic-setupv2 --skill xlsx-mccleod1290

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires openpyxl, pandas, defusedxml, lxml, and includes scripts (resource) components.

What problem does it solve? Spreadsheet tasks often produce broken formulas, hardcoded values, and inconsistent formatting when done ad hoc. This Skill provides a disciplined workflow for creating, editing, and analyzing .xlsx, .xlsm, .csv, and .tsv files so every deliverable uses live Excel formulas, follows financial-modeling conventions, and ships with zero formula errors. ## Core Features & Use Cases - Formula-first spreadsheet generation: Builds workbooks with openpyxl using real Excel formulas (SUM, AVERAGE, growth rates) instead of Python-hardcoded values, keeping files dynamic and recalculable. - Mandatory recalculation and error scanning: The scripts/recalc.py tool drives LibreOffice headlessly to recalculate all formulas and reports any #REF!, #DIV/0!, #VALUE!, #NAME?, or #N/A errors with exact cell locations. - Financial modeling standards: Enforces industry color conventions (blue inputs, black formulas, green cross-sheet links), number formatting rules, and source documentation for hardcoded values. - Use Case: A user asks to build a revenue projection model from a messy CSV export. The Skill cleans the data with pandas, constructs a formatted workbook with assumption cells and formulas, recalculates it via LibreOffice, and fixes any reported errors before delivery. ## Quick Start Ask the assistant to create an Excel financial model from your data file with formulas for totals and growth rates, then recalculate and verify it contains no formula errors.

Frequently Asked Questions about xlsx

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create an Excel file with formulas in Python?▼

Use openpyxl to write formula strings like '=SUM(B2:B9)' directly into cells, then save the workbook. Run scripts/recalc.py afterward so LibreOffice recalculates all formulas and reports any errors with cell locations.

Should I use pandas or openpyxl for Excel files?▼

Use pandas for data analysis, bulk operations, and simple exports via read_excel and to_excel. Use openpyxl when you need formulas, cell formatting, multiple sheets, or edits to existing workbooks while preserving their structure.

Why do openpyxl formulas show no calculated values?▼

openpyxl stores formulas as strings but never evaluates them, so saved files lack computed results. Recalculate with LibreOffice using scripts/recalc.py, which updates all values and scans every cell for Excel errors.

How do I fix #REF! and #DIV/0! errors in generated spreadsheets?▼

Run scripts/recalc.py and inspect the JSON error_summary, which lists each error type with up to 20 cell locations. Fix invalid references, guard divisions against zero denominators, then recalculate again until status is success.

Can I read Excel formula results without losing the formulas?▼

Load with openpyxl using data_only=True to read cached calculated values, but never save from that object because saving replaces formulas with values permanently. Keep a separate load_workbook call without data_only for edits.