Undefined symol: Class CMdaAudioPlayerUtility
| Mon, 2008-03-17 13:17 | |
|
Hi, Actually I wrote my own class in which I declared an object pointer for CMdaAudioPlayerUtility class Please help me out. Best Regards PK |
|
| Mon, 2008-03-17 13:17 | |
|
Hi, Actually I wrote my own class in which I declared an object pointer for CMdaAudioPlayerUtility class Please help me out. Best Regards PK |
|
Forum posts: 1134
Undefined symbol means that the compiler can't find the definition for the symbol.
You must make sure that each .cpp file that uses this symbol has access to the header file it is declared in...
To me, it sounds like you have written the code for your constructors in the .h-file of your class, but then only include the header for CMdaAudioPlayerUtility in the .cpp file.
That way, it will work fine to compile your original class, but you would get undefined symbol when trying to use it in another .cpp file without including the header for CMdaAudioPlayerUtility.
Study patterns for how to organize your cpp/header files in C++, and you will avoid problems like this.
Forum posts: 132
I bet it won't be the header file that is missing but the .lib.
Forum posts: 5
Hi Alert,
Thnx for ur help