Re: Statement cannot resolve adress of overloaded function
Please post your well indented code in [code][/code] bbcode tags.
It looks like you did not actually call the function, i.e., you wrote myBook.displayMessage instead of myBook.displayMessage().
Other things to note: do not use using declarations (e.g., using std::cout) before including a header. In other words, these three lines:
Code:
using std::cout;
using std::cin;
using std::endl;
should be moved to after the #include <string>. The reason is that if you have a using declaration before a header inclusion, the contents of that header could be affected by the using declaration. This applies to using directives as well (e.g., using namespace std).
In fact, as a matter of good habit for the future, consider doing without using declarations and using directives before your class definition, since that is how you would do it when you move your class definition to a header file.
C + C++ Compiler: MinGW port of GCC
Build + Version Control System: SCons + Bazaar
Bookmarks