Skip to content

TediTae/mail-merging-project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Mail Merge Automation Project 📩

Description

This Python project automates the creation of personalized letters using a mail merge technique. It reads a list of names and a letter template, then generates custom letters for each name by replacing placeholders in the template.

Features

  • Reads names from a .txt file
  • Loads a letter template containing placeholder [name]
  • Replaces the placeholder with each person's name
  • Saves the output letters as .docx files in a target folder
  • Efficient use of file handling and string replacement

How It Works

  1. The program reads a file of names (invited_names.txt).
  2. It also loads a template letter (starting_letter.txt) that contains [name] as a placeholder.
  3. For each name, it:
    • Removes any whitespace
    • Replaces [name] with the actual name
    • Saves the result as a new file: letter_for_<Name>.docx in the Output/ReadyToSend folder

Folder Structure

📁 Input ├── 📁 Names │ └── invited_names.txt └── 📁 Letters └── starting_letter.txt 📁 Output └── 📁 ReadyToSend └── letter_for_.docx

Technologies Used

  • Python 3
  • File I/O
  • String manipulation
  • Looping & logic

Installation & Usage

  1. Clone the repository
  2. Replace the invited_names.txt and starting_letter.txt with your own data.
  3. Run the script:
    • main.py

License

  • This project is open source and available under the MIT License.

Contact

About

This Python project takes a set of names, formats them into a list, and generates personalized .docx documents for each name using a predefined message template. It’s particularly useful for tasks such as generating invitations, certificates, or other bulk personalized documents.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages