A desktop application for managing real estate properties built using pure Win32 API in C++. This system provides user authentication, property management, and advanced search capabilities with a clean graphical interface.
- User Registration: Create new user accounts with password confirmation
- User Login: Secure authentication system
- Access Control: Login required to access property management features
- Add Properties: Add new property listings with details:
- Property Type (House, Apartment, Villa, etc.)
- Location
- Price
- Area (in square feet)
- Owner Name
- View All Properties: Display all properties in a sortable list view
- Auto-clear Forms: Input fields automatically clear after successful property addition
- Search by Type: Find properties by type (case-insensitive)
- Search by Location: Filter properties by location
- Search by Exact Price: Binary search for exact price match
- Search by Price Range: Find properties within a minimum and maximum price range
- Sort by Price: Bubble sort algorithm to organize properties by price
- Properties saved to
properties.csv - User credentials stored in
users.csv - Automatic loading on application startup
- Language: C++
- GUI Framework: Win32 API
- Controls: Common Controls Library (comctl32)
- Data Structure: Vector of tuples for property storage
- File I/O: CSV-based file handling
- Bubble Sort: For sorting properties by price in ascending order
- Binary Search: For exact price lookup (requires sorted data)
- Linear Search: For type and location searches
- Operating System: Windows 7 or later
- Compiler:
- Visual Studio (MSVC) with C++ support, OR
- MinGW-w64 (GCC for Windows)
- Required Libraries: comctl32.lib, gdi32.lib
# Navigate to project directory
# Compile the application
g++ main.cpp -o RealEstateApp.exe -lcomctl32 -lgdi32 -mwindows
# Run the application
.\RealEstateApp.exe# Open Visual Studio Developer Command Prompt and navigate to project directory
# Compile with MSVC
cl /EHsc main.cpp /link comctl32.lib user32.lib gdi32.lib /SUBSYSTEM:WINDOWS /ENTRY:WinMainCRTStartup
# Run the application
.\main.exe- Launch the application
- You'll see the Login section by default
- Use the navigation buttons at the top to switch between sections
- Click "Register" button
- Enter your desired username
- Enter a password
- Confirm your password
- Click "REGISTER"
- You'll be redirected to the login page
- Click "Login" button (if not already on login page)
- Enter your username
- Enter your password
- Click "LOGIN"
- Upon successful login, you'll be redirected to the Search Property section
- Click "Add Property" button in the navigation bar
- Fill in all fields:
- Type: e.g., House, Apartment, Villa, Land
- Location: e.g., Mumbai, Delhi, Bangalore
- Price: Enter numeric value
- Area: Enter area in square feet (numeric)
- Owner: Owner's name
- Click "Add Property"
- The property list will update automatically
- Input fields will be cleared for the next entry
- Click "Show All (Sorted)" to display all properties sorted by price
- Click "Sort by Price" to sort currently displayed properties
- Enter property type in the "Type" field
- Click "Search by Type"
- Enter location in the "Location" field
- Click "Search by Location"
- Enter exact price in the "Exact Price" field
- Click "Search Exact Price" (uses binary search)
- Enter minimum price in the "Min Price" field
- Enter maximum price in the "Max Price" field
- Click "Search Price Range"
Project/
β
βββ main.cpp # Main application source code
βββ RealEstateApp.exe # Compiled executable
βββ properties.csv # Property data storage (auto-generated)
βββ users.csv # User credentials storage (auto-generated)
βββ README.md # This file
IDC_BTN_SECTION_LOGIN(50)IDC_BTN_SECTION_REGISTER(51)IDC_BTN_SECTION_SEARCH(52)IDC_BTN_SECTION_ADD(53)
IDC_LOGIN_USERNAME(60)IDC_LOGIN_PASSWORD(61)IDC_BTN_LOGIN(62)
IDC_REG_USERNAME(70)IDC_REG_PASSWORD(71)IDC_REG_CONFIRM_PASS(72)IDC_BTN_REGISTER(73)
IDC_TYPE(101)IDC_LOCATION(102)IDC_PRICE(103)IDC_AREA(104)IDC_OWNER(105)IDC_BTN_ADD(201)
IDC_SEARCH_TYPE(110)IDC_SEARCH_LOCATION(111)IDC_SEARCH_PRICE(112)IDC_SEARCH_MIN_PRICE(113)IDC_SEARCH_MAX_PRICE(114)
IDC_BTN_SHOW(202)IDC_BTN_SORT(203)IDC_BTN_SEARCH_TYPE(204)IDC_BTN_SEARCH_LOC(205)IDC_BTN_SEARCH_RANGE(206)IDC_BTN_SEARCH_EXACT(207)
Type,Location,Price,Area,Owner
HOUSE,MUMBAI,5000000,1500,John Doe
APARTMENT,DELHI,3500000,1200,Jane Smith
VILLA,BANGALORE,8000000,2500,Bob Johnson
username,password
admin,admin123
user1,pass123
β οΈ Note: Passwords are stored in plain text. This is suitable for educational purposes only. In production, always use proper password hashing (e.g., bcrypt, SHA-256).
- Window Size: 780 x 640 pixels (fixed size)
- Background Color: Alice Blue (RGB: 240, 248, 255)
- Layout: Section-based navigation with dedicated panels
- ListView: 6 columns (No., Type, Location, Price, Area, Owner)
- Plain Text Passwords: User passwords are stored in plain text in
users.csv. For production use, implement proper password hashing. - File Permissions: CSV files have no access restrictions. Consider implementing file encryption for sensitive data.
- Input Validation: Basic validation is implemented, but additional sanitization may be needed for production.
- Ensure you have a C++ compiler installed (MinGW or Visual Studio)
- Check that comctl32 and gdi32 libraries are linked properly
- Verify all required Windows SDK components are installed
- Files are created automatically on first use
- Ensure the application has write permissions in the directory
- Type and Location searches are case-insensitive
- Exact price search requires the list to be sorted first
- Check that your search criteria match existing properties
- Password encryption/hashing
- Property image support
- Export to PDF/Excel functionality
- Property editing and deletion
- Advanced filtering (multiple criteria)
- User roles (Admin/User)
- Property booking/reservation system
- Database integration (SQLite/MySQL)
Sahil
Computer Science Student