A simple Python utility to convert text columns in Excel (.xlsx, .xls) and CSV (.csv) files to Title Case (e.g., "SHAHRIAR PARVEZ" -> "Shahriar Parvez").
- Multi-Format Support: Works with
.csv,.xlsx, and.xlsfiles. - Smart Detection: Automatically detects file format and uses the appropriate method to read/write.
- Robust: Handles missing files and permission errors (e.g., if the file is open in Excel).
- Easy to Use: Simply place your file in the directory, configure the script, and run.
- Python 3.x
- pandas
- openpyxl (for Excel support)
-
Clone this repository or download the files.
-
Install the required packages:
pip install -r requirements.txt
-
Place your data file (e.g.,
example.csv) in the project directory. -
Open
main.pyand update theINPUT_FILEvariable with your filename:INPUT_FILE = "example.csv" OUTPUT_FILE = "example_proper.csv"
-
Run the script:
python main.py
-
The script will generate a new file (e.g.,
example_proper.csv) with all text columns converted to Title Case.
This project is open-source and available under the MIT License.