A sleek GUI-based desktop application built in C# with Windows Forms = mini-project.
The Vehicle Rental System is a user-friendly application that allows customers to rent vehicles (Cars or Vans) by selecting models, destinations, and locations. It calculates rental costs for single-day and two-day periods, demonstrating encapsulation and polymorphism in a clean Windows Forms interface.
Developed for the IT21053 mini-project, this project showcases object-oriented programming principles with a focus on simplicity and functionality.
- Vehicle Selection:
- 🛻 Cars: Alto, Prius, Axio.
- 🚐 Vans: KDH, HiAce, Every.
- Dynamic Cost Calculation:
- Costs vary by vehicle type and destination:
- Car: Colombo (Rs. 5000), Kandy (Rs. 6000), Galle (Rs. 6500).
- Van: Colombo (Rs. 8000), Kandy (Rs. 10000), Galle (Rs. 10500).
- Supports single-day and two-day rentals.
- Costs vary by vehicle type and destination:
- Intuitive Interface:
- Form1: Select vehicle, model, destination, and location using ComboBoxes.
- Form2: Displays rental details and costs with a return button.
- Seamless Navigation:
- Calculate costs and view results in Form2.
- Return to Form1 with a single click.
This project implements two core OOP principles:
- 🔒 Encapsulation:
- Private fields (
model,type) inVehicle.csare accessed via public properties (Model,Type), ensuring data integrity. - Example: Form2 safely displays vehicle details like "Car - Alto".
- Private fields (
- 🔄 Polymorphism:
- Method Overriding:
CalculateCostinCar.csandVan.csprovides vehicle-specific pricing. - Method Overloading:
CalculateCostinVehicle.cshandles single-day and multi-day rentals. - Example: Form2 shows tailored costs based on vehicle and destination.
- Method Overriding:
- Language: C#
- Framework: .NET Framework 4.8
- GUI: Windows Forms
- IDE: Visual Studio 2022
- Version Control: Git & GitHub
- Visual Studio 2022 with .NET Framework 4.8.
- Git (optional for cloning).