But the complier complaint:
1>f:\vz test\vz test\pes_supplement.cpp(7): error C2653: 'File_element' : is not a class or namespace name
1>f:\vz test\vz test\pes_supplement.cpp(8): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
I don't understand why do these errors occur.
First thing I notice is you are using C, C++ mix.
For file handling in C++ use fstream header and ifstream and ofstream for input and out from/to files.
Instead of printf use cout, you need to include header iostream for it to work.
About the errors: I dont see any class related code at line 7 and function declaration/definition at line 8.
Is the source different from the one posted here?
Looking at the code I dont see apparent cause except what ne555 pointed out
Oh I forget. I delete lines for you guys easier to see. I compile it again
1>f:\vz test\vz test\pes_supplement.cpp(4): error C2653: 'File_element' : is not a class or namespace name
1>f:\vz test\vz test\pes_supplement.cpp(5): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
After put stdafx first, things work normal again. Thanks ne555 for helping.