我的是win2k,vc6.0,
我建了一个win32 console application
然后自建了一个class,calss放在一个自建的head file和.app中,但编译时报以下错误fatal error C1010: unexpected end of file while looking for precompiled header directive
Error executing cl.exe.11_3.exe - 1 error(s), 0 warning(s)
我建了一个win32 console application
然后自建了一个class,calss放在一个自建的head file和.app中,但编译时报以下错误fatal error C1010: unexpected end of file while looking for precompiled header directive
Error executing cl.exe.11_3.exe - 1 error(s), 0 warning(s)
解决方案 »
- 孙鑫老师的mfc教程 挺难听懂的,求高手
- ░▒▓█ VC里怎么用.net的PictureBox控件?
- BMP文件格式读取(特殊)
- 想请教大家一个利用VLC接口写播放器的问题,谢谢!
- 怎样同时更新Splitter window里pane的大小?
- 新手问VC6用DAO操作ACCESS的老问题
- 我的窗口不包含控件,如何在当鼠标在客户区时显示tooltip
- 如何查找带“‘”的问题
- 高分相求!!如何得到CRichEditCtrl控件中鼠标位置下当前的字符串行数???
- 请问关于ADO的数据连接的问题
- ▲▲▲我发现一个好的工具软件,愿与大家分享http://xmsoft.xiloo.com
- 在windows98下怎样用windows API 取得中文字符的宽度?
我在.h中申明了成员函数,再在同名.pp中定义为什么会报错?//date.h
class Tdate
{
public:
void print();
void addoneday();
void setdate(int,int,int);
protected:
int month,year,day;
};
//date.cpp
#include "date.h" //申明class的头文件
#include <iostream.h>
#include "stdafx.h"void Tdate::print()
{
cout<<day<<"/"<<month<<"/"<<year
<<endl;
}void Tdate::addoneday()
{
if(month==2)
{
if((year%4==0&&year%100!=0)||(year%400==0))
if(day==28)
{
day=1;
month=3;
return;
}
if(day==27)
{
day=1;
month=3;
return;
}
}
if(month=12)
{
if(day==31)
{
day=1;
month=1;
year+=1;
return;
}
}
if(month==1||month==3||month==5||month==7||month==8||month==10)
{
if(day==31)
{
day=1;
month+=1;
return;
}
}
else if(day==30)
{
day=1;
month+=1;
return;
}
day+=1;
}
void Tdate::setdate(int year,int month,int day)
{
// if((year<0 || year>9999 || month<1 || month>12 || day<1 || day>31)
// ||(month=2&&(((year%4==0&&year%100!=0)||(year%400==0))&&day>28)||day>27))
this->year = year;
this->month = month;
this->day = day;
}
#include <iostream.h>
#include "date.h" //申明class的头文