p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


  Return to Index  

proasp_codeclinic thread: Connecting to an SQL Server Database keep getting ADODB.Fields error '800a0cc1' !!!


Message #1 by jlock@d... on Tue, 22 Aug 2000 13:8:28
This line here, sorry it's a bit tricky to show when you paste it..The last
four fields are the ones causing the problems...

Much Appreciated...

href=""javascript:changePages('help2.asp','resrightform.asp','lessonplan.asp
?sGroup="
& orsla.Fields("ResourceLibraryName").value & "&sContributor=" &
orsla.Fields("Contributor").value & "&sSubmittedDate=" &
orsla.Fields("SubmittedDate").value & "&SubjectIconFile=" &
orsLA.Fields("SubjectIconFile").value & "&sSubjectName=" &
orsla.Fields("SubjectName").value & "&AgeRangeIconFile=" &
orsLA.Fields("AgeRangeIconFile").value & "&sProgrammeOfStudyName=" &
orsla.Fields("ProgrammeOfStudyName").value & "&sURLLessonPlans=" &
orsLA.Fields("LessonPlans").Value & "&sURLStudentActivities=" &
orsLA.Fields("StudentActivities").Value & "&sURLHomeworkTasks=" &
orsLA.Fields("HomeworkTasks").value & "&sURLRevisionGuides=" &
orsLA.Fields("RevisionGuides").value & "');"">")%>

James Lock

-----Original Message-----
From: Jo Ryall 
Sent: Tuesday, August 22, 2000 1:37 PM
To: Code Clinic
Subject: [proasp_codeclinic] RE: Connecting to an SQL Server Database
keep getting ADODB.Fields error '800a0cc1' !!!


Which is line 363?

-----Original Message-----
From: jlock@d... [mailto:jlock@d...]
Sent: 22 August 2000 13:00
To: Code Clinic
Subject: [proasp_codeclinic] Connecting to an SQL Server Database keep
getting ADODB.Fields error '800a0cc1' !!!


I am currently working on a webpage by where I am accessing a table in a
Database using ASP, and a DLL that I have written to carry out the SQL
Query. This was working fine until I decided that I required four more
database fields returned so I added these to the Table and set up my ASP to
return them. I am now getting the Error as shown below,

ADODB.Fields error '800a0cc1'

ADO could not find the object in the collection corresponding to the name
or ordinal reference requested by the application.

/resources/Resourcemain.asp, line 363.

If I take out the four extra fields then the page works fine. I have tried
stopping IIS, deleting the old dll, recompiling the new dll and
un-registering and registering it. This makes no difference.The fields
definitely exist in the Database and if I run the same sql query I have in
the DLL though Query Analyzer it brings back the correct recordset.The asp
sample code is shown below,

IF orsLA.Fields("LevelofServiceID").value = 3 then

IF nUserID = 2 or nUserID = 3 then%>
<td width="60"><%Response.Write ("<a
href=""javascript:changePages('help2.asp','resrightform.asp','lessonplan.asp
?sGroup="
& orsla.Fields("ResourceLibraryName").value & "&sContributor=" &
orsla.Fields("Contributor").value & "&sSubmittedDate=" &
orsla.Fields("SubmittedDate").value & "&SubjectIconFile=" &
orsLA.Fields("SubjectIconFile").value & "&sSubjectName=" &
orsla.Fields("SubjectName").value & "&AgeRangeIconFile=" &
orsLA.Fields("AgeRangeIconFile").value & "&sProgrammeOfStudyName=" &
orsla.Fields("ProgrammeOfStudyName").value & "&sURLLessonPlans=" &
orsLA.Fields("LessonPlans").Value & "&sURLStudentActivities=" &
orsLA.Fields("StudentActivities").Value & "&sURLHomeworkTasks=" &
orsLA.Fields("HomeworkTasks").value & "&sURLRevisionGuides=" &
orsLA.Fields("RevisionGuides").value & "');"">")%>
<img name="image9" src="images/go.gif" border="0" WIDTH="20"
HEIGHT="20"></td>
<%iLinkSet = true %>
<%end if%>

<%elseIF orsLA.Fields("LevelofServiceID").value = 2 then
IF nUserID = 1 or nUserID = 3 then %>
<td width="60"><%Response.Write ("<a
href=""javascript:changePages('help2.asp','resrightform.asp','lessonplan.asp
?sGroup="
& orsla.Fields("ResourceLibraryName").value & "&sContributor=" &
orsla.Fields("Contributor").value & "&sSubmittedDate=" &
orsla.Fields("SubmittedDate").value & "&SubjectIconFile=" &
orsLA.Fields("SubjectIconFile").value & "&sSubjectName=" &
orsla.Fields("SubjectName").value & "&AgeRangeIconFile=" &
orsLA.Fields("AgeRangeIconFile").value & "&sProgrammeOfStudyName=" &
orsla.Fields("ProgrammeOfStudyName").value & "&sURLLessonPlans=" &
orsLA.Fields("LessonPlans").Value & "&sURLStudentActivities=" &
orsLA.Fields("StudentActivities").Value & "&sURLHomeworkTasks=" &
orsLA.Fields("HomeworkTasks").value & "&sURLRevisionGuides=" &
orsLA.Fields("RevisionGuides").value & "');"">")%>
<img name="image9" src="images/go.gif" border="0" WIDTH="20"
HEIGHT="20"></td>
<%iLinkSet = true %>
<%end if%>
<%elseif orsLA.Fields("LevelofServiceID").value = 1 then %>
<td width="60"><%Response.Write ("<a
href=""javascript:changePages('help2.asp','resrightform.asp','lessonplan.asp
?sGroup="
& orsla.Fields("ResourceLibraryName").value & "&sContributor=" &
orsla.Fields("Contributor").value & "&sSubmittedDate=" &
orsla.Fields("SubmittedDate").value & "&SubjectIconFile=" &
orsLA.Fields("SubjectIconFile").value & "&sSubjectName=" &
orsla.Fields("SubjectName").value & "&AgeRangeIconFile=" &
orsLA.Fields("AgeRangeIconFile").value & "&sProgrammeOfStudyName=" &
orsla.Fields("ProgrammeOfStudyName").value & "&sURLLessonPlans=" &
orsLA.Fields("LessonPlans").Value & "&sURLStudentActivities=" &
orsLA.Fields("StudentActivities").Value & "&sURLHomeworkTasks=" &
orsLA.Fields("HomeworkTasks").value & "&sURLRevisionGuides=" &
orsLA.Fields("RevisionGuides").value & "');"">")%>
<img name="image9" src="images/go.gif" border="0" WIDTH="20"
HEIGHT="20"></td>
<%iLinkSet = true %>
<%end if%>

I need this solved asap as it is very urgent...Any help would be greatly
appreciated...

James Lock (WebDeveloper)





  Return to Index