...

View Full Version : whats this error: E_FAIL status??



homerUK
12-04-2002, 09:44 AM
I just got this error message on one of the ASP pages on my site.. any ideas??



Microsoft Cursor Engine error '80004005'

Data provider or other service returned an E_FAIL status.

/features.asp, line 65


Line 65 is: "Page_Count = RS.PageCount"

It works on another page I have used, just for some reason, not this one!

Thanks....

Morgoth
12-04-2002, 01:22 PM
It would help more if you posted the code.
A single line tells us nothing.

Usually when you have something that has more then one line of code in it and you get an error, the error is probibly on one line of code that the error report doesn't tell you, because it's just showing you the executed line, we need to know what your executing to debug it.

Know what I mean?

Roelf
12-04-2002, 02:31 PM
it is a cursor engine error, maybe the cursor action you want is not supported by the cursortype you defined for the recorset you created

homerUK
12-04-2002, 02:37 PM
ok, sorry bout that guys!!
here's some more of the code....



If Request("pageno")="" Then
Current_Page = 1
Else
Current_Page = CInt(Request("Pageno")) 'the CInt function converts the value to an integer.
End If

Page_Size = 5

Set MyConn = Server.CreateObject("ADODB.Connection")
Set RS = Server.CreateObject("ADODB.RecordSet")
MyConn.Open strConnect

RS.CursorLocation = adUseClient
RS.PageSize = Page_Size

SQL = "SELECT features.featureID, features.body, features.hits, features.status, members.memberID, members.username, features.memberID, features.category, features.title, features.date_submitted, features.public FROM members INNER JOIN features ON members.memberID = features.memberID WHERE features.public = 'Y';"

RS.Open SQL, MyConn, adOpenStatic, adLockReadOnly, adCmdText

'this page_count is the part which the browser says is the problem
Page_Count = RS.PageCount

If 1 > Current_Page Then Current_Page = 1
If Current_Page > Page_Count Then Current_Page = Page_Count

if RS.EOF then
'no records
records = 0
current_page = 1
else
RS.AbsolutePage = Current_Page
Records = RS.RecordCount
end if



what's annoying is I have the exact same code for another page (this one is "features" and the other is "news") and that works perfectly!!

Thanks again..... :thumbsup:

glenngv
12-05-2002, 03:34 AM
did you include the file adovbs.inc in the page?

homerUK
12-05-2002, 10:10 AM
yeah, the adovbs.inc is included.. I have narrowed the problem down to something wrong with the table.... I just dont know what!

I used the code in my post above but I changed the SQL statement to the most basic one to see if it was that...

"SELECT * from features" ... it still had the same error. Then I changed the table from features to "news" and it worked fine. Thats all I changed!! and the error vanished!!

So any ideas what might be wrong with the table?

It seems to work ok with the admin panel.. ie: I can get records to display and update... but I dont seem to be able to use the pageCount request........

Thanks for the help guys!

:confused:

homerUK
12-05-2002, 10:12 AM
oh, just one more thing (in the words of the great columbo ;-) )...

it seems to work on my local server (IIS) ... just not on the W2K host server!!

how confusing!!

homerUK
12-05-2002, 10:30 AM
I found the error....!!

It was a field in the DB... when I downloaded the current DB.. there was a field contents called "#ERROR" and when I clicked it... it said "Another user is trying to update this record" something wrong with the "Jet Engine"?!

So I deleted it and re-uploaded the DB... now it works fine!

What might have caused that error?!
:rolleyes:



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum