Windows 7下的VB6错误,但不是XP:recordset.Update或UpdateBatch [英] VB6 error under Windows 7, but not XP: recordset.Update or UpdateBatch

查看:90
本文介绍了Windows 7下的VB6错误,但不是XP:recordset.Update或UpdateBatch的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好,


在Windows 7上部署旧版vb6应用程序后,出现以下错误。


运行时错误-2147217904(80040e10)没有给出一个或多个必需参数的值


在记录集上执行操作更新或UpdateBatch时会发生这种情况。


1 。我将 adocd UI组件(MSAdodcLib的一部分)的记录集源设置如下:

 myAdodc.RecordSource =" ; SELECT * FROM a  INNER JOIN b ON a。[id] = b。[ida]  WHERE [f] = 2 AND [g] ="" foo""" 

2。从UI修改记录集的值后,RS.UpdateBatch和错误引发。这种情况发生在Win 7,Win 8和Vista上。


这是由于API签名的变化吗?我是否需要安装旧版Windows库?


我的应用程序链接到以下内容,默认情况下主要出现在win 7操作系统中(并不意味着它们未与应用程序一起部署,否则他们是):

 C:\ WINDOWS \ system32 \ msvbvm60.dll = No 
C:\Program Files \\ \\ Microsoft Visual Studio \ VB98 \ Wizards \ PDWizard \ Redist\OLEAUT32.DLL = No
C:\Program Files \ Microsoft Visual Studio\VB98 \ Wizards\PDWizard \ Reded \ OLEPRO32.DLL = No
C:\Program Files\Microsoft Visual Studio \ VB98 \ Wizards\PDWizard\Redist\ASYCFILT.DLL = No
C:\ Program Files\Microsoft Visual Studio \ VB98 \ Wizards\PDWizard\Redist\STDOLE2.TLB = No
C:\Program Files \ Microsoft Visual Studio\VB98 \ Wizards\PDWizard \\ \\ reded\COMCAT.DLL = No
C:\ WINDOWS \ system32 \ msbind.dll =是
C:\ WINDOWS \system32 \ msstdfmt.dll =是
C:\Program Files \ Common Files\Microsoft Shared\DAO\dao360.dll = No
C:\ WINDOWS \system32 \ msjet40.dll = No
C:\ WINDOWS \ systemL \ msjter40.dll = No
C:\ WINDOWS \ system32 \ msjint40.dll = No
C:\ WINDOWS \system32 \ vbajet32.dll = No
C:\ WINDOWS \ systemL \ expsrv.dll = No
C:\\ \\ WINDOWS \ system32 \ mswstr10.dll = No
C:\ WINDOWS \ systemL \ mswdat10.dll = No
C:\ WINDOWS \ system32 \ msrd2x40.dll = No
C:\ WINDOWS \ system32 \ msrd3x40.dll = No
C:\ WINDOWS \ system32 \ msrepl40.dll = No
C:\ WINDOWS \ system32 \ msjtes40.dll = No
C:\ WINDOWS \system32 \VB5DB.DLL = No
C:\ WINDOWS \ system32 \ msadodc.ocx = Yes
C :\ WINDOWS \ system32 \msdatgrd.ocx = Yes
C:\ WINDOWS \ system32 \ MSCOMCTL.OCX = No
C: \\ Program Files \Common Files\System\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ Fred

解决方案

>>


RS。 RecordSource =" SELECT * FROM a  INNER JOIN b on a。[id] = b。[ida]  WHERE [f] = 2 AND [g] =" foo"


<<<


我认为您没有在上述声明中发布正确的详细信息,原因有两个:


1. 我从来没有听说过Recordset的RecordSource属性(DAO或ADO)。 对象浏览器也没有显示这样的东西。


2.  SQL发布的双引号不平衡,双引号中嵌入双引号的常见问题。


也许,你应该发布确切的声明(或者更好的相关报表块,以便论坛成员也可以查看背景详细信息。


 



Hello,

After deploying a legacy vb6 application on windows 7, I get the following error.

run-time error -2147217904 (80040e10) No value given for one or more required parameters

It happens when executing the operation update or UpdateBatch on a recordset.

1. I set the recordset source of an adocd UI component (part of the MSAdodcLib) as following:

myAdodc.RecordSource = "SELECT * FROM a INNER JOIN b ON a.[id] = b.[ida] WHERE [f] = 2 AND [g] = ""foo"""

2. After modifying a value of the recordset from the UI, the RS.UpdateBatch and the error raises. This happens on Win 7, Win 8 and probably Vista.

Is this due to a change in the API signature? Do I need to install legacy windows libraries?

My application is linking to the following which are mostly present in the win 7 OS by default (no mean they are not deployed with the application, otherwise they are):

C:\WINDOWS\system32\msvbvm60.dll=No
C:\Program Files\Microsoft Visual Studio\VB98\Wizards\PDWizard\Redist\OLEAUT32.DLL=No
C:\Program Files\Microsoft Visual Studio\VB98\Wizards\PDWizard\Redist\OLEPRO32.DLL=No
C:\Program Files\Microsoft Visual Studio\VB98\Wizards\PDWizard\Redist\ASYCFILT.DLL=No
C:\Program Files\Microsoft Visual Studio\VB98\Wizards\PDWizard\Redist\STDOLE2.TLB=No
C:\Program Files\Microsoft Visual Studio\VB98\Wizards\PDWizard\Redist\COMCAT.DLL=No
C:\WINDOWS\system32\msbind.dll=Yes
C:\WINDOWS\system32\msstdfmt.dll=Yes
C:\Program Files\Common Files\Microsoft Shared\DAO\dao360.dll=No
C:\WINDOWS\system32\msjet40.dll=No
C:\WINDOWS\system32\msjter40.dll=No
C:\WINDOWS\system32\msjint40.dll=No
C:\WINDOWS\system32\vbajet32.dll=No
C:\WINDOWS\system32\expsrv.dll=No
C:\WINDOWS\system32\mswstr10.dll=No
C:\WINDOWS\system32\mswdat10.dll=No
C:\WINDOWS\system32\msrd2x40.dll=No
C:\WINDOWS\system32\msrd3x40.dll=No
C:\WINDOWS\system32\msrepl40.dll=No
C:\WINDOWS\system32\msjtes40.dll=No
C:\WINDOWS\system32\VB5DB.DLL=No
C:\WINDOWS\system32\msadodc.ocx=Yes
C:\WINDOWS\system32\msdatgrd.ocx=Yes
C:\WINDOWS\system32\MSCOMCTL.OCX=No
C:\Program Files\Common Files\System\ado\msjro.dll=No

Thanks for your help.

Fred

解决方案

>>

RS.RecordSource = "SELECT * FROM a INNER JOIN b ON a.[id] = b.[ida] WHERE [f] = 2 AND [g] = "foo"

<<

I don't think you posted the correct details with the above statement for 2 reasons:

1.  I have never heard of RecordSource Property of a Recordset (DAO or ADO).  The Object Browser does not show such thing, either.

2.  The SQL posted has unbalanced double-quotes and possible, common problems with double-quote(s) embedded in the double-quote-delimited String.

Perhaps, you should post the exact statement (or better the relevant block of statements so that forum members can see the backgroud details also.

 


这篇关于Windows 7下的VB6错误,但不是XP:recordset.Update或UpdateBatch的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆