当前位置:首页 » 软件开发
开发技术指南» 文章正文
    引言: Environment: Visual C++ 6Microso
 

 

 ·ado操作数据的几个问题     »显示摘要«
    摘要:总结了几个在用ado操作数据库的时候常遇见的问题。1读数据库中的二进制数据,在论坛里有人提到用getchunk不行,只能读image类型的数据,下面是一个声音数据的例子:long ldatasize = m_adorecordset.getfields()->getitem("声音")->actualsize;if(ldatasize > 0){ _varia......
    摘要:1.引入ado库文件   使用ado前必须在工程的stdafx.h文件里用直接引入符号#import引入ado库文件,以使编译器能正确编译。代码如下所示:  #import "c:\program files\common files\system\ado\msado15.dll"   no—namespaces rename("eof" ad......


Using ADO from C++
environment:  visual c++ 6

microsoft activex data object (ado) provides an easy way to data access and manipulation that is independent of data stores, tools, and languages. this flexibility and easy-to-code facility makes ado the perfect choice for developers. ado is implemented with component object model (com) interfaces. unlike vb programmers, c++ programmers must know the details of using com for using ado. so, using ado from c++ is still very complex. but, it is possible to get an easy ado programming model from c++, which can help to hide the details of using com. in this article, i demonstrate a c++ class to do this that encapsulates the ado connection object. you can apply same technique for encapsulating other ado objects.

one way to add ado support to your c++ program is to import ado type library information. the type library for the current ado is contained within the ado dll, msado15.dll. you can import this type library by importing msado15.dll by using the #import directive: 【程序编程相关:2个CString的小错误,记下来时时提

adding ado support to a c++ program 【推荐阅读:利用VC制作动态连接库(.dll)(采用


...   下一页
    摘要:ado是应用层的编程接口,它通过ole db提供的com接口访问数据,它适合于各种客户机/服务器应用系统和基于web的应用,尤其在一些脚本语言中访问数据库操作是ado的主要优势。ado是一套用自动化技术建立起来的对象层次结构,它比其他的一些对象模型如dao(data access object)、rdo(remote data object)等具有更好的灵活性,使用更为方便,并且访问数据的效率更高......
» 本期热门文章:

©2000-2007 All Rights Reserved. 最佳浏览:1024X768 MSIE