Hello, when im trying to build my project im getting "<class name> does not name a type" (on the line "DataBase db;//an object of class DataBase" of Menu.h)
However, in file Menu.cpp (that includes Menu.h), all the functions and objects related to database do work.
I've tried rebuilding.
#ifndef __MENU_H__
#define __MENU_H__
#include "DataBase.h"
#define MAX_STRING_SIZE 120//max size of strings in this program.
#define DB_TYPE 0 //0 for Array DataBase , 1 for Linked List DataBase
//main class - provide the main menu for the user to activate and manage the Employess database.
class Menu{
public:
typedefenum {ADD_EMPLOYEE = 1, REMOVE_EMPLOYEE, PRINT_ALL_EMPLOYEES, PROMOTE_EMPLOYEE, EXIT} MenuOption;
//enum of menu options.
void mainMenu();//the methods that run the main menu for this program. Resposible to input / ouput with the user.
private:
DataBase db;//an object of class DataBase
//private menthods:
void printOptions() const;//print all the menu options to screen.
void addEmp();//input all the nessesary data to create a new Employess and add it to the Data-Base
void removeEmp();//input the index and remove the asked Employee fro mthe database
void printDB() const;//print the entire database
void promoteEmp();//input the index and promote the asked Employee in the database.
};
#endif //__MENU_H__