Wrox Programmer Forums

Need to download code?

View our list of code downloads.

| FAQ | Members List | Search | Today's Posts | Mark Forums Read
Classic ASP Databases Discuss using ASP 3 to work with data in databases, including ASP Database Setup issues from the old P2P forum on this specific subtopic. See also the book forum Beginning ASP.NET Databases for questions specific to that book. NOT for ASP.NET 1.0, 1.1, or 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Classic ASP Databases section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old August 31st, 2004, 01:45 PM
Friend of Wrox
 
Join Date: Jun 2004
Location: Montreal, Quebec, Canada.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default ADODB.Recordset error '800a0e78'

Hi, I'm trying to create a dynamic table populated with employee contact info. I know there must be a lot of canned soluitions, but thought I try it. Unfdortunately I'm getting the error message in my subject line.
************************************************** *********
ADODB.Recordset error '800a0e78'
Operation is not allowed when the object is closed.

/HR/EMPLOYEE_DIRECTORY/directory.asp, line 41
************************************************** *********

Here's what's on Line 41:

************************************************** *********
Line 41: <% do until rsEmployees.eof =true %>
************************************************** *********

... and the rest of the code to generate the table follows as such:


<tr>
    <td><%=(rsEmployees.Fields.Item("EmployeesID").Val ue)%></td>
    <td><%=(rsEmployees.Fields.Item("DepartmentName"). Value)%></td>
    <td><%=(rsEmployees.Fields.Item("Last_Name").Value )%></td>
    <td><%=(rsEmployees.Fields.Item("First_Name").Valu e)%></td>

************************************************** *********
... and so on.. until I have this other piece of code:

<%
  rsEmployees.MoveNext
loop
%>
</table>


Any help would greatly reduce my frustration <smile!>
Thanks all,
Nancy
Reply With Quote
  #2 (permalink)  
Old August 31st, 2004, 01:56 PM
Friend of Wrox
 
Join Date: Jun 2003
Location: Harrisburg, PA, USA.
Posts: 1,998
Thanks: 0
Thanked 3 Times in 3 Posts
Default

Hey,

What about the code above that line? That is where your problem is going to be. Post that too.

Brian
Reply With Quote
  #3 (permalink)  
Old August 31st, 2004, 02:00 PM
Friend of Wrox
 
Join Date: Jun 2004
Location: Montreal, Quebec, Canada.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hey, thanks for your quick response...
Here's what's before Line 41:

************************************************** **********


<%
Dim rsEmployees
Dim rsEmployees_numRows

Set rsEmployees = Server.CreateObject("ADODB.Recordset")
'rsEmployees.ActiveConnection = MM_employee_directory_STRING
rsEmployees.Source = "SELECT * FROM Employees ORDER BY Last_Name ASC"
rsEmployees.CursorType = 0
rsEmployees.CursorLocation = 2
rsEmployees.LockType = 1
'rsEmployees.Open()
%>
<table border="1" cellpadding="0" cellspacing="4">
  <tr>
    <td>EmployeesID</td>

... and so on...

************************************************** ***************

Nancy
Reply With Quote
  #4 (permalink)  
Old September 1st, 2004, 08:12 AM
Friend of Wrox
 
Join Date: Jun 2004
Location: Montreal, Quebec, Canada.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Brian, do you need more info?
Reply With Quote
  #5 (permalink)  
Old September 1st, 2004, 09:11 AM
Friend of Wrox
 
Join Date: Jun 2003
Location: Harrisburg, PA, USA.
Posts: 1,998
Thanks: 0
Thanked 3 Times in 3 Posts
Default

Hey,

You have the rsEmployees.Open() method commented out. That needs to be there for you to access the properties.

Brian
Reply With Quote
  #6 (permalink)  
Old September 1st, 2004, 09:22 AM
Friend of Wrox
 
Join Date: Jun 2004
Location: Montreal, Quebec, Canada.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thx, Brian for getting back to me. 'K, I removed the "comment out", so that that line is read, (not sure why I did a stupid thing like that to begin with, but anyway...)

I'm still getting errors ; Here it is:

ADODB.Recordset error '800a0e7d'

The connection cannot be used to perform this operation. It is either closed or invalid in this context.

/HR/EMPLOYEE_DIRECTORY/directory.asp, line 25

Oddly enough, that line is EXACTLY the line we just put back in??

Line 25: rsEmployees.Open()
Reply With Quote
  #7 (permalink)  
Old September 1st, 2004, 09:42 AM
Friend of Wrox
 
Join Date: Jun 2004
Location: Montreal, Quebec, Canada.
Posts: 106
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thx Brian for all your help. This problem is solved.

Have a great day!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ADODB.Recordset error 800a0e78 quinnie Classic ASP Databases 6 October 2nd, 2007 05:13 PM
ADODB.Recordset error lance Wrox Book Feedback 2 February 23rd, 2007 02:37 PM
ADODB.RecordSet -- Error nabeeljohn Classic ASP Professional 10 November 9th, 2006 05:23 AM
ADODB.Recordset error '800a0e78' Orpheus Classic ASP Databases 2 March 27th, 2006 10:05 AM
ADODB.Recordset error '800a0cc1'Item cannot be.... ashu_gupta75 Classic ASP Databases 1 March 5th, 2004 03:50 AM



All times are GMT -4. The time now is 05:28 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.