This i the code i have used and for some reason its saying there are undeclared identifiers
#include <string>
#include <iostream>
#include "stdafx.h"
using namespace std;
int main()
{
bool Firstboot = true;
EntryPoint();
cout << "Hello World!" << endl;
return 0;
}
int MainMenu()
{
FormatedOut("MainMenu", "Menu1", "Menu1");
}
int Menu1()
{
FormatedOut("Menu1", "SubMenuOption1", "SubMenuOption1");
}
int EntryPoint() {
FormatedOut("MainMenu", "Menu1", "Menu1");
string option;
cin >> option;
if (option == "1")
{
Menu1();
}
}
int FormatedOut(string MenuName, string FirstOption, string FirstOptionTarget) {
cout << "----------------";
cout << "| " + MenuName;
cout << "|---------------";
cout << "| ";
cout << "| " + FirstOption;
EntryPoint();
}
I have codded this in C++ on Visual Studio 2017
The errors i have been getting for the past half an hour
C3861 'EntryPoint': identifier not found 8
C2065 'cout': undeclared identifier 9
C2065 'endl': undeclared identifier 9
C3861 'FormatedOut': identifier not found 15
C3861 'FormatedOut': identifier not found 19
C3861 'FormatedOut': identifier not found 24
C2065 'string': undeclared identifier 26
C2065 'option': undeclared identifier 26
C2065 'cin': undeclared identifier 27
C2065 'option': undeclared identifier 27
C2065 'option': undeclared identifier 28
C2065 'string': undeclared identifier 34
Any help that you can give me will be greatly appreciated