F
fl
Hi,
I am learning C++ from the following C++ website, which has some very
good small examples. For the second Fraction example, which has five
files:
Main.cpp
Fraction.cpp
Fraction.h
msoftcon.cpp
msoftcon.h
,,,,,
A Fraction class that has the ability to add, subtract, multiply,
divide and show various statistics of the fraction.
http://www.cplusplus.com/src/
,,,,,,,,,,,,,
When I compile them, MSVC 6++ compiler says:
error C2653: 'Fraction' : is not a class or namespace name
if I put Fraction.h with the .cpp under Source Files category.
If I put Fraction.h under Header Files category, the compiler cannod
find the .h file. I have also tried Settings in the Project menu
without success. I am new to MSVC and C++, could you help me the
settings? Thank you very much.
I am learning C++ from the following C++ website, which has some very
good small examples. For the second Fraction example, which has five
files:
Main.cpp
Fraction.cpp
Fraction.h
msoftcon.cpp
msoftcon.h
,,,,,
A Fraction class that has the ability to add, subtract, multiply,
divide and show various statistics of the fraction.
http://www.cplusplus.com/src/
,,,,,,,,,,,,,
When I compile them, MSVC 6++ compiler says:
error C2653: 'Fraction' : is not a class or namespace name
if I put Fraction.h with the .cpp under Source Files category.
If I put Fraction.h under Header Files category, the compiler cannod
find the .h file. I have also tried Settings in the Project menu
without success. I am new to MSVC and C++, could you help me the
settings? Thank you very much.