0
C++ Code Block
Hi! Can me someone help me to understand why I have by Code Block this problem #include "MyClass.h" #include <iostream> using namespace std; MyClass::MyClass() { } void MyClass::myPrint(){ cout<<"Hello"<<endl; } // After run I have this error >> ---Error: no member function "void MyClass :: myPrint ()" declared in class "MyClass" |--- Hi! I didn't make it, Do you know any if there is a helpful introduction on Youtube?
3 Answers
+ 1
I recommend finishing sololearn's c++ course.
It explains about operating with classes using multiple files.
0
Dear friend you write class and do not declare function but write the definition. Just add void myPrint(); between class brackets in correponding h file
0
Hi!
Dear George
I didn't make it, Do you know any if there is a helpful introduction on Youtube?