C++ Code 
1
2
3
 
// Import the ADO type library
#import "C:\\Program Files\\Common Files\\system\\ado\\msadox.dll"  
#import "C:\\Program Files\\Common Files\\System\\ado\\msado15.dll" no_namespace rename ("EOF","adoEOF")

  以下网上流传的方法,被转来转去,然而试了没啥作用!

 C++ Code 
1
2
3
4
5
6
7
8
9
10
11
12
13
 
// 1)
)
#import "C:/Program Files/Common Files/System/ADO/msado15.dll" named_guids rename("EOF","adoEOF"), rename("BOF","adoBOF")
)
using namespace ADODB;
// 2)
)
#import "C:/Program Files/Common Files/System/ado/msado15.dll" /
no_namespace /
rename("EOF","adoEOF") rename("DataTypeEnum","adoDataTypeEnum") /
rename("FieldAttributeEnum", "adoFielAttributeEnum") rename("EditModeEnum", "adoEditModeEnum") /
rename("LockTypeEnum", "adoLockTypeEnum") rename("RecordStatusEnum", "adoRecordStatusEnum") /
rename("ParameterDirectionEnum", "adoParameterDirectionEnum")

  最终有效的方法:(VC++6.0)Project ->Setting -> C/C++ ->perprocessor ->perprocessor definitions :  里面添加 宏   _AFX_NO_DAO_SUPPORT

 

ADO编程:error C2011: 'LockTypeEnum' : 'enum' type redefinition的更多相关文章

  1. 解决ERROR C2011: 'FD_SET' : 'STRUCT' TYPE REDEFINITION问题

    在socket编程的过程中头文件中 #include <windows.h> #include "stdafx.h" #include "WinSock2.h ...

  2. VC中编译报错:error C2011: 'fd_set' : 'struct' type redefinition

    这是头文件包含顺序的问题,原因与解决办法见下面代码的注释. /* 包含下面这两个头文件时,必须把winsock2.h放在前面 否则编译报错,N多的重定义错误:例如 error C2011: 'fd_s ...

  3. 解决error C2011: 'fd_set' : 'struct' type redefinition的方法

    http://www.cnblogs.com/ark-zhang/archive/2013/06/19/3144383.html   首先说明这个问题由于重复定义引起的编译错误. 先说明解决方法,然后 ...

  4. “locktype”enum type 类型重定义问题的解决

    作者:朱金灿 来源:http://blog.csdn.net/clever101 使用ado来连接数据库,结果出现这样一些编译错误: 1>f:\c++pro\iocptser\debug\msa ...

  5. Visual C++中的ADO编程

    摘  要:本文介绍了微软推出的以ActiveX技术为基础的ADO数据存取技术,分析了ADO的工作原理,并用Visual C++说明了ADO数据访问技术的实现方法. 关键字:ADO:连接对象:OLE D ...

  6. Delphi多线程下的ADO编程

    前言: 几个月前接到一个任务:将一后台程序访问数据库的方式从BDE改为ADO,原因是由于业务量的增加,通过BDE不论是向数据库写入数据还是从数据库中读出数据的速度都变得无法忍受,大家都知道ADO在数据 ...

  7. System.Net.WebException : The remote server returned an error: (415) UNSUPPORTED MEDIA TYPE

    I am having problems with a bit of code that accesses a restful web service. Running this code, it e ...

  8. Effective Java 03 Enforce the singleton property with a private constructor or an enum type

    Principle When implement the singleton pattern please decorate the INSTANCE field with "static ...

  9. caffe: fuck compile error again : error: a value of type "const float *" cannot be used to initialize an entity of type "float *"

    wangxiao@wangxiao-GTX980:~/Downloads/caffe-master$ make -j8find: `wangxiao/bvlc_alexnet/spl': No suc ...

随机推荐

  1. RGB和HSL色彩的相互转换

    转自: http://blog.csdn.net/aniven/article/details/2205851 RGB和HSL(也叫HSB/HSV)是两种色彩空间,即:红,绿,蓝(Red,Green, ...

  2. WKWebView的使用

    代码地址如下:http://www.demodashi.com/demo/13431.html 前言 最近项目中的UIWebView被替换为了WKWebView,因此来总结一下WKWebView的使用 ...

  3. Mybatis准备

    http://www.mybatis.org/mybatis-3/zh/index.html

  4. mybatis加入条件

    根据http://www.cnblogs.com/friends-wf/p/3799315.html搭建的环境 User.xml加入的 if where判断的 <!-- 根据条件查询一个用户 - ...

  5. 阿里云web播放器

    原文地址:https://help.aliyun.com/document_detail/51991.html?spm=5176.doc61109.6.703.ZTCYoi 一.概念说明 1. pla ...

  6. STL容器分析--vector

    vector是一种动态数组,是基本数组的类模板. vector,支持随机访问.在数据结构上,属于顺序线性表. 而且,由于是动态数组,

  7. Java编程介绍

    原文地址:http://happyshome.cn/blog/java/introduction.html 本文介绍的编程基础知识很Java适合刚開始学习的人. 要学习编程,你须要了解编程语言的语法和 ...

  8. MongoDB GridFS规范

    This is being changed for 2.4.10 and 2.6.0-rc3. Tyler Brock's explanation: Now that the server uses ...

  9. MySQL分组查询获取每个学生前n条分数记录(分组查询前n条记录)

    CREATE TABLE `t_test` ( `id` ) NOT NULL AUTO_INCREMENT, `stuid` ) NOT NULL, `score` ) DEFAULT NULL, ...

  10. iOS直播-基于RTMP的视频推送

    iOS直播-基于RTMP的视频推送 所谓的视频推送就是把摄像头和麦克风捕获到视频和音频推送到直播服务器上.我们这里使用推送协议是RTMP协议. 扩展:腾讯直播平台,阿里直播平台,百度直播平台提供均为R ...