春暖花开
雪化了,花开了,春天来了
posts - 149,comments - 125,trackbacks - 0

今天在加数据库的相关操作时,遇到了一些问题,提示

error C3861: 'CeMountDBVolEx': identifier not found
error C3861: 'CeMountDBVolEx': identifier not found
error C3861: 'CeCreateDatabaseWithProps': identifier not found
error C3861: 'CeCreateSession': identifier not found
error C3861: 'CeOpenDatabaseInSession': identifier not found

我在.cpp文件的开头加入了

#define EDB
#include <windows.h>
#include <windbase.h>

但是错误还依然存在

从网上搜索了一些方法

在博文《mobile数据库遇到的问题》

http://blog.sina.com.cn/s/blog_4c5ad0740100cvxg.html

它里面建议使用

extern "C"
{
  #include <windbase_edb.h>
}

但是使用后,问题变成了lnk的错误

error LNK2019: unresolved external symbol

有人在论坛里建议

#include Windbase_edb.h

也是同样的问题

最后,我问了一下我的同事

他建议我在

stdafx.h 头文件中添加

#define EDB
#include <windows.h>
#include <windbase.h>

这样的确解决了问题。

posted on 2009-02-04 13:20 Sandy 阅读(455) 评论(0)  编辑 收藏 引用 所属分类: windows学习

只有注册用户登录后才能发表评论。
网站导航: 博客园   IT新闻   BlogJava   知识库   博问   管理