# Python Tkinter Student Registration Form

TechBuilt Open School — Free, self-guided technical project kit

- **Track:** Desktop Applications
- **Level:** Beginner
- **Access:** No account, signup, payment or enrollment required
- **Format:** Guided plan and runnable starter example, not a complete solution or a live class
- **Online guide:** https://techbuiltos.online/projects/tkinter-student-form

## Project goal

Understand Tkinter widgets, event handlers and basic GUI validation before integrating a real local database.

Build a Python desktop registration window with validated inputs and later add safe local SQLite persistence.

## Before you begin

- Python 3 with Tkinter available
- Functions, strings and basic Python error handling

## Local setup

1. Save the starter as app.py on a desktop computer with GUI access.
2. Run python app.py; it requires a local graphical environment.
3. When the form is stable, extend it with sqlite3 and parameterized queries.

## Starter example — app.py

The sample below is a starting point. It may require the prerequisites above. Complete the subsequent milestones to finish your own project.

```python
import tkinter as tk
from tkinter import messagebox

root = tk.Tk()
root.title("Practice Student Form")
root.geometry("320x180")
name = tk.StringVar()

tk.Label(root, text="Student name").pack(pady=(12, 4))
tk.Entry(root, textvariable=name).pack()

def save():
    value = name.get().strip()
    if not value:
        messagebox.showerror("Missing name", "Please enter a name.")
        return
    messagebox.showinfo("Validated", "Form input is valid (not saved yet).")

tk.Button(root, text="Validate", command=save).pack(pady=16)
root.mainloop()
```

## Build milestones

1. Create labels, entry controls and a clearly named Save button.
2. Validate names and grades with helpful errors; avoid blank entries.
3. Display a confirmation without storing personal data in logs.
4. Save records in a local SQLite database with prepared/parameterized queries.
5. Add a searchable records view and a basic manual test checklist.

## Completion checklist

- [ ] A blank name is rejected clearly.
- [ ] Valid test inputs show a confirmation.
- [ ] After storage is implemented, reopening the app retrieves records.
- [ ] Private personal information is not printed or sent to third-party services.

## Optional extensions

- Add role-aware UI patterns after discussing local security boundaries.
- Package a tested desktop executable using PyInstaller with accurate setup notes.

## Related learning

- Individual course roadmap: https://techbuiltos.online/courses/oop
- Individual course roadmap: https://techbuiltos.online/courses/sql

- Specialization: https://techbuiltos.online/specializations/python-desktop-application-developer
- Specialization: https://techbuiltos.online/specializations/python-developer

---

This original self-study project is independent of paid cohorts. Review any external library documentation before use. Do not commit real credentials, private client files or personal data to public repositories.
