| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 768 人关注过本帖
标题:MFC图形文件的保存与打开问题
只看楼主 加入收藏
weilinfeng
Rank: 1
等 级:新手上路
帖 子:1
专家分:0
注 册:2006-12-24
收藏
 问题点数:0 回复次数:0 
MFC图形文件的保存与打开问题
void CDraw3Doc::Serialize(CArchive& ar)
{
POSITION pos=GetFirstViewPosition();
CDraw3View *pView=(CDraw3View*)GetNextView(pos);
if (ar.IsStoring())
{
// TODO: add storing code here
int nCount=pView->m_ptrArray.GetSize();
ar<<nCount;
for(int i=0;i<nCount;i++)
{
ar<<pView->m_ptrArray.GetAt(i);
}
}
else
{
// TODO: add loading code here
int nCount;
ar>>nCount;
CGraph *pGraph;
for(int i=0;i<nCount;i++)
{
ar>>pGraph;
pView->m_ptrArray.Add(pGraph);
}
error C2678: binary '<<' : no operator defined which takes a left-hand operand of type 'class CArchive' (or there is no acceptable conversion)
error C2679: binary '>>' : no operator defined which takes a right-hand operand of type 'class CGraph *' (or there is no acceptable conversion)
谁能帮忙看一下,解决一下了谢谢了
搜索更多相关主题的帖子: MFC 图形 nCount int 文件 
2007-06-12 19:34
快速回复:MFC图形文件的保存与打开问题
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.013718 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved