473,397 Members | 2,028 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

I have got error Microsoft VBScript runtime (0x800A01FB)

Hi All,Please help me check my code. I have got running time error (0x800A01FB).An exception occurred: 'objConn.Execute'

some records execute but some records don't. I have no idea how to solve them.
Thanks a lot.
Here is my code
Expand|Select|Wrap|Line Numbers
  1. dim i_svAppDbConnstr, i_svDBConn
  2. i_svAppDbConnstr = "Provider=OraOLEDB.Oracle;Data Source=database_name;User Id=user_id;Password=password;"
  3.  
  4. Set i_svDBConn = OpenConn(i_svAppDbConnstr)
  5.  
  6. Function OpenConn(strConnStr)
  7.     Dim objDbConn
  8.     Set objDbConn = Server.CreateObject("ADODB.Connection")
  9.     objDbConn.CursorLocation = 3
  10.     objDbConn.Open strConnStr
  11.     Set OpenConn = objDbConn
  12. End Function
  13. Function GetData(strQuery, objConn)
  14. 'On Error Resume Next
  15.     Dim objRS
  16.     Set objRS = objConn.Execute(strQuery) ' this line is error.
  17.     Set GetData = objRS
  18. End Function 
  19. Function GetAppData(strQuery)
  20.     Set GetAppData = GetData(strQuery, i_svDbConn)
  21. End Function
  22.  
  23. 'I call the GetAppData function.
  24. strsql = "Select * from ARTICLE where ART_NR = '" & trim(replace(reqName,"'","''")) & "'"
  25. Set rstTrans = GetAppData(strSQL)
  26.  
Apr 15 '08 #1
1 2694
DrBunchman
979 Expert 512MB
Hi jimmylee,

There isn't a problem with your code (it works fine on my machine) but there it may be that you need to install a newer version of the MDAC (Microsoft Data Access Components). Basically this contains things like the ODBC drivers that hook you up to your databases and there is a bug in earlier releases that sometimes causes the problem you describe.

You can download the latest version of it here. Give it a try and see if it solves your problem.

Let me know how you get on.

Dr B
Apr 15 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Luis | last post by:
My page is producing the following error: Microsoft VBScript runtime (0x800A01FB) An exception occurred: 'Execute' Validate.asp, line 15 The affected code (line 15) in Validate.asp is: Set...
5
by: Arun Wadhawan | last post by:
Hello MY SQL Server is causing me this problem : Microsoft VBScript runtime error '800a000d' Type mismatch: 'ident' >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> I am getting from...
6
by: amitavabardhan | last post by:
How can I return an error code from a sql server stored procedure and use it in my asp page to generate an alert indicating that some error has ocurred?
0
by: ann | last post by:
Hi, I am trying to add an ActiveX control on my ASP.NET web form (the language for code behind is C#). I have some client-side vbscript to handle events from the html input buttons. In the...
1
by: PaulieS | last post by:
Hi all. Am migrating a customer from IIS5 on W2K server to IIS6 on W2K3. Zipped all the websites and unzipped them to the identical locations on new server. Used IISMT to migrate metabase. ...
11
by: Jerry | last post by:
I'm using this code: Dim strName For Each strName in Session.Contents Response.Write strName & " - " & Session.Contents(strName) & "<BR>" Next If I only do a response.write strName, it shows...
2
by: amitpatil | last post by:
Hi, I have 4 web pages which collects data and insert in database. Since couple of days i am getting following errors. ( there r diff kinds of errors i get each time ): They are in sequence as i...
2
by: anidmarty | last post by:
Hey I'm a Sysadmin and my users are getting this error on my production box. It works fine on the dev box. There is a script that is run that generates this error. Production is clustered...
4
by: Genken | last post by:
Hi can anybody help me i get this error when running this code. Error Type: Microsoft VBScript runtime (0x800A01A8) Object required: '' And then a line number indicating where the error is, i...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.