Syntax Error with EditMenu

This is a discussion on Syntax Error with EditMenu within the C++ Programming forums, part of the General Programming Boards category; I can't spot this error and thought it may be in one of the headers included but they compile fine ...

  1. #1
    Registered User
    Join Date
    Jul 2003
    Posts
    450

    Syntax Error with EditMenu

    I can't spot this error and thought it may be in one of the headers included but they compile fine I'm sure it's somthing stupid.
    Code:
    #include <iostream>
    using std::cout;
    using std::endl;
    using std::left;
    
    #include <iomanip>
    using std::setw;
    
    #include <map>
    using std::map;
    
    #include "menu.h"
    #include "book.h"
    
    EditMenu::EditMenu(){}
    
    EditMenu::EditMenu(std::map<string,Book> & rlibrary){
        ptrLibrary=&rlibrary;
    }
    
    void EditMenu::display_menu() const{
        cout << "\t\tEdit Menu\n";
        cout << "1.  Display Library\n";
        cout << "2.  Edit Book\n";
        cout << "3.  Remove Book\n";
        cout << "4.  Add Book\n";
        cout << "5.  Display Book\n";
        cout << "6.  Main Menu"<<endl;
    }
    editmenu.cpp:15: syntax error before `::' token

    editmenu.cpp:17: syntax error before `::' token
    editmenu.cpp:21: syntax error before `::' token
    editmenu.cpp:23: syntax error before `<<' token
    editmenu.cpp:24: syntax error before `<<' token
    editmenu.cpp:25: syntax error before `<<' token
    editmenu.cpp:26: syntax error before `<<' token
    editmenu.cpp:27: syntax error before `<<' token
    editmenu.cpp:28: syntax error before `<<' token

    editmenu.cpp:31: syntax error before `::' token
    editmenu.cpp:39: syntax error before `::' token
    editmenu.cpp:50: syntax error before `.' token
    editmenu.cpp:52: syntax error before `.' token
    editmenu.cpp:67: syntax error before `::' token

    editmenu.cpp:72: parse error before `for'
    editmenu.cpp:72: syntax error before `!=' token
    editmenu.cpp:74: syntax error before `<<' token
    editmenu.cpp:77: syntax error before `::' token
    editmenu.cpp:78: syntax error before `::' token
    editmenu.cpp:79: syntax error before `::' token
    Last edited by curlious; 09-29-2003 at 09:05 AM.

  2. #2
    Registered User
    Join Date
    Jul 2003
    Posts
    450
    never mind forgot to include "editmenu.h"

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. more then 100errors in header
    By hallo007 in forum Windows Programming
    Replies: 20
    Last Post: 05-13-2007, 08:26 AM
  2. We Got _DEBUG Errors
    By Tonto in forum Windows Programming
    Replies: 5
    Last Post: 12-22-2006, 04:45 PM
  3. Using VC Toolkit 2003
    By Noobwaker in forum Windows Programming
    Replies: 8
    Last Post: 03-13-2006, 06:33 AM
  4. Connecting to a mysql server and querying problem
    By Diod in forum C++ Programming
    Replies: 8
    Last Post: 02-13-2006, 09:33 AM
  5. Dikumud
    By maxorator in forum C++ Programming
    Replies: 1
    Last Post: 10-01-2005, 06:39 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21