What library does ObjectContext come from in VB5?

限于喜欢 提交于 2019-12-11 03:41:13

问题


First of all, let me myself make the obligatory snarky comment about having to maintain VB5 code: yes, it's pitiful, but can we please just cut to the chase? Thanks.

I am having to revisit some VERY old code that was written in 1998 and which hasn't been touched since 2003. The problem I am having is that I am getting a compile error on this:

Dim ObjCtx As ObjectContext

The VB5 compiler throws a compile error: User-defined type not defined

This is not of course a user-defined type, but is a part of some libary or another. My problem is that I don't know which library I might be missing. The workstation is reconstructed from an old Windows 2000 workstation, and not all libraries may have been installed. I am suspecting that ObjectContext might be a part of some version of ADO (ActiveX Data Objects), of which only v2.1 is currently installed.

Are there any old-timers out there who remember anything about this?


回答1:


You need to add a reference to your project for "COM+ Services Type Library" (COMSVCS.DLL)



来源:https://stackoverflow.com/questions/8766401/what-library-does-objectcontext-come-from-in-vb5

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!