0x80004002 no such interface supported
在Win10下的vfp9 sp2里预编译、设置项目信息、再编译成的多线程的dll
编译结束的时候提示注册失败
管理员身份运行命令行
在 C:\Windows\SysWow64下 手工注册该dll成功
但是用CreateObject或NewObject调用时
提示'OLE error 0x80004002: no such interface supported'
想通过向导发布web服务,选定该dll后
提示该dll包含非法类库
是什么问题啊,求高手指点
程序代码:
DEFINE CLASS ManaSystUser as Session OLEPUBLIC DataSession=2 PROCEDURE GetUerList HelpString "获取用户列表" LOCAL oXmlAdap as XMLAdapter ,oCursAdap as String,cXml as String oCursAdap=CREATEOBJECT("iCursAdap") oCursAdap.CursorFill() oXmlAdap=NEWOBJECT("XmlAdapter") oXmlAdap.AddTableSchema(oCursAdap.Alias) oXmlAdap.ToXml("cXml") RELEASE oCursAdap,oXmlAdap RETURN cXml ENDPROC ENDDEFINE DEFINE CLASS iCursAdap as CursorAdapter Alias="SystUser" BreakOnError='F' DataSourceType="ODBC" Tables="SystUser" *!* SendUpdates=.T. &&是否向更新表发送SQL更新查询 *!* AllowDelete=.T. *!* AllowInsert=.T. *!* AllowUpdate=.T. *!* UpdateType=1 && 1-用新数据替换旧数据 2-删除旧数据,插入新数据 *!* WhereType=1 *!* KeyFieldList="" *!* UpdatableFieldList="" *!* UpdateNameList="" *!* BufferModeOverride=5 cConnStr="driver=sql server;server=114. .234..;uid=ffsfs;pwd=aaadadadadd;database=ws_analyze" PROCEDURE init this.DataSource=SQLSTRINGCONNECT(this.cConnStr) this.SelectCmd="select * from dbo.ActiExpeChec_SystUser" this.CursorSchema="uid I,user_name c(25),pass_word c(32),whic_tool c(35)" ENDPROC FUNCTION Destroy() SQLDISCONNECT(this.DataSource) ENDFUNC ENDDEFINE
注册文件VBR
程序代码:
VB5SERVERINFO VERSION=1.0.0 HKEY_CLASSES_ROOT\mycomsvr.ManaSystUser = mycomsvr.ManaSystUser HKEY_CLASSES_ROOT\mycomsvr.ManaSystUser\NotInsertable HKEY_CLASSES_ROOT\mycomsvr.ManaSystUser\CLSID = {331DF8BB-2E49-43A8-9050-3554694BF57B} HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B} = mycomsvr.ManaSystUser HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B}\ProgId = mycomsvr.ManaSystUser HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B}\VersionIndependentProgId = mycomsvr.ManaSystUser HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B}\InProcServer32 = mycomsvr.dll HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B}\InProcServer32\"ThreadingModel" = Apartment HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B}\TypeLib = {905FC70C-EB10-44E2-8892-2D8F54A6AE79} HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B}\Version = 1.0 HKEY_CLASSES_ROOT\CLSID\{331DF8BB-2E49-43A8-9050-3554694BF57B}\Foxruntime = VFP9T.DLL HKEY_CLASSES_ROOT\INTERFACE\{239D302C-49FB-49A8-8999-7221FA3F4835} = ManaSystUser HKEY_CLASSES_ROOT\INTERFACE\{239D302C-49FB-49A8-8999-7221FA3F4835}\ProxyStubClsid = {00020424-0000-0000-C000-000000000046} HKEY_CLASSES_ROOT\INTERFACE\{239D302C-49FB-49A8-8999-7221FA3F4835}\ProxyStubClsid32 = {00020424-0000-0000-C000-000000000046} HKEY_CLASSES_ROOT\INTERFACE\{239D302C-49FB-49A8-8999-7221FA3F4835}\TypeLib = {905FC70C-EB10-44E2-8892-2D8F54A6AE79} HKEY_CLASSES_ROOT\INTERFACE\{239D302C-49FB-49A8-8999-7221FA3F4835}\TypeLib\"Version" = 1.0 ; TypeLibrary registration HKEY_CLASSES_ROOT\TypeLib\{905FC70C-EB10-44E2-8892-2D8F54A6AE79} HKEY_CLASSES_ROOT\TypeLib\{905FC70C-EB10-44E2-8892-2D8F54A6AE79}\1.0 = mycomsvr Type Library HKEY_CLASSES_ROOT\TypeLib\{905FC70C-EB10-44E2-8892-2D8F54A6AE79}\1.0\0\win32 = mycomsvr.dll HKEY_CLASSES_ROOT\TypeLib\{905FC70C-EB10-44E2-8892-2D8F54A6AE79}\1.0\FLAGS = 0
[此贴子已经被作者于2018-6-21 14:55编辑过]