πŸ“Š

Sheet Splitter

Split Excel workbook sheets into separate files.

Excel ⭐ Beginner ⏱️ 2 minutes

😫 The Pain Point

You have a single Excel file with 12 sheets (one per month). You need to send each month’s data to a different person as separate files.

πŸš€ Agentic Solution

A Sheet Splitter that exports each tab as its own file.

Key Features:

  • Individual Files: One file per sheet.
  • Naming Pattern: Use sheet name as filename.
  • Format Options: XLSX or CSV output.

βš”οΈ Phase 1: Commander (Quick Fix)

For quick splitting.

Prompt:

β€œI have an Excel file annual_report.xlsx with 12 sheets. Write a Python script using Pandas to:

  1. Split: Each sheet into a separate file.
  2. Naming: Use sheet name (e.g., January.xlsx).
  3. Output: Save to split_sheets/ folder.

Print progress. Handle empty sheets (skip with warning).”

Result: 12 separate files ready for distribution.

πŸ—οΈ Phase 2: Architect (Permanent Tool)

Engineering Prompt:

**Role:** Python Tool Developer
**Task:** Create a "Sheet Splitter".

**Requirements:**
1.  **GUI:**
    *   Select Excel file.
    *   Show sheet list with checkboxes.
    *   Output format (XLSX, CSV).
    *   Naming pattern input.
    *   Progress bar.

2.  **Logic:**
    *   Use openpyxl for sheet reading.
    *   Preserve formatting if possible.
    *   Handle special characters in sheet names.

3.  **Deliverables:**
    *   `sheet_splitter.py`
    *   `run.bat`, `run.sh`
    *   `requirements.txt`

🧠 Prompt Decoding

  • Preserve Formatting: CSV loses formatting; XLSX keeps it.

πŸ› οΈ Instructions

  1. Copy Prompt β†’ Run.

Related Workflows

Explore other categories

πŸ“¬

Get Started with Agentic Working

Subscribe to receive updates from AgenticWorking.io

πŸ“– Free eBook Guide πŸ“¦ 7 Ready-to-use Scripts πŸ”” Weekly Tips

No spam, unsubscribe anytime. Join 1,000+ subscribers.