Que
September 17th, 1999, 09:17 AM
I wrote 2 files, "Extra.h" and "Extra.cpp"
Why the compiler said:
c:\my documents\receipt\extra.cpp(21) : fatal error C1010: unexpected end of file while looking for precompiled header directive
here is the code of extra.cpp
// implementation of extra functions
/////////////////////////////////////
// change to real date value
void ToReal(int &nDay,int &nMonth,int &nYear)
{
nDay=nDay+1;
nMonth=nMonth+1;
nYear=nYear+1999;
}
// change to combo box value
void ToFake(int &nDay,int &nMonth,int &nYear)
{
nDay=nDay-1;
nMonth=nMonth-1;
nYear=nYear-1999;
}
Here is the header file Extra.h
// this file to contain prototype for extra functions
///////////////////////////////////////////////////
// change value of m_nDay, m_nMonth and m_nYear back and forth
//change to real value of date
void ToReal(int &nDay,int &nMonth,int &nYear);
// change to combo box value
void ToFake(int &nDay,int &nMonth, int &nYear);
Thanks
Why the compiler said:
c:\my documents\receipt\extra.cpp(21) : fatal error C1010: unexpected end of file while looking for precompiled header directive
here is the code of extra.cpp
// implementation of extra functions
/////////////////////////////////////
// change to real date value
void ToReal(int &nDay,int &nMonth,int &nYear)
{
nDay=nDay+1;
nMonth=nMonth+1;
nYear=nYear+1999;
}
// change to combo box value
void ToFake(int &nDay,int &nMonth,int &nYear)
{
nDay=nDay-1;
nMonth=nMonth-1;
nYear=nYear-1999;
}
Here is the header file Extra.h
// this file to contain prototype for extra functions
///////////////////////////////////////////////////
// change value of m_nDay, m_nMonth and m_nYear back and forth
//change to real value of date
void ToReal(int &nDay,int &nMonth,int &nYear);
// change to combo box value
void ToFake(int &nDay,int &nMonth, int &nYear);
Thanks