Print Page | Close Window

Rowset does not support fetching backward

Printed From: Web Wiz Forums
Category: General Discussion
Forum Name: Classic ASP Discussion
Forum Description: Discussion on Active Server Pages (Classic ASP).
URL: https://forums.webwiz.net/forum_posts.asp?TID=5153
Printed Date: 30 March 2026 at 10:31pm
Software Version: Web Wiz Forums 12.08 - https://www.webwizforums.com


Topic: Rowset does not support fetching backward
Posted By: ivonda
Subject: Rowset does not support fetching backward
Date Posted: 20 August 2003 at 10:56am

Hi,

Can someone help me out? Because I don't know what to do if I get this error.

I have this error:

Microsoft OLE DB Provider for ODBC Drivers (0x80040E24)
Rowset does not support fetching backward. 
line 81 | objRS.Move rndNumber


Please if someone can help I would be very very happy

With kind regards,

Ivonda Marsman




Replies:
Posted By: stephen
Date Posted: 20 August 2003 at 12:28pm

try adding the following code just after setting the record set.

 rs.CursorType = adOpenStatic
  ' Use client cursor to enable AbsolutePosition property.
 rs.CursorLocation = adUseClient



-------------
"Doing easily what others find difficult is talent; Doing what is impossilbe for talent is genius." -- Henri Frederic Amiel ( 1828-1881)
http://www.121People.com - www.121People.com


Posted By: Bunce
Date Posted: 21 August 2003 at 3:42am

Great site from a fellow Aussie:
http://www.adopenstatic.com/faq/jetcursortypes.asp - http://www.adopenstatic.com/faq/jetcursortypes.asp

Should explain everything.

Cheers,
Andrew



-------------
There have been many, many posts made throughout the world...
This was one of them.


Posted By: ivonda
Date Posted: 21 August 2003 at 7:39am
Originally posted by stephen stephen wrote:

try adding the following code just after setting the record set.

 rs.CursorType = adOpenStatic
  ' Use client cursor to enable AbsolutePosition property.
 rs.CursorLocation = adUseClient

Where does this record set begin?



Posted By: stephen
Date Posted: 21 August 2003 at 2:18pm

wherever you have

set rs = CreateObject ("ADODB.RecordSet")



-------------
"Doing easily what others find difficult is talent; Doing what is impossilbe for talent is genius." -- Henri Frederic Amiel ( 1828-1881)
http://www.121People.com - www.121People.com


Posted By: b_bonnett
Date Posted: 22 August 2003 at 4:29am

(Somewhat unrelated question):
Why do you have the following code:

objRS.MoveFirst
Do While Not objRS.EOF 
objRS.MoveNext
LOOP
objRS.MoveFirst

All it does is move to the first record, loop through each record one by one, without referencing any values, and then move back to the first record again. As far as I can see, all it is doing is wasting time and processor power. I would suggest deleting everything in that block of code except the first line.

Blair



-------------
Webmaster, http://www.planegallery.net/ - The Plane Gallery
Greetings From Christchurch


Posted By: ivonda
Date Posted: 22 August 2003 at 9:48am

Hi everyone,

It's working, but I don't have a random banner but just the first in the database. Did I deleted to much code? Or must I add a code to get a random banner, every time a page loads?

I have deleted this line:
Conn.Execute(SQL)



Posted By: b_bonnett
Date Posted: 22 August 2003 at 5:33pm

If you want a random banner ad, then use Microsoft's Ad Rotator component. Click http://www.w3schools.com/asp/asp_adrotator.asp - here for details on how to use it.

Blair



-------------
Webmaster, http://www.planegallery.net/ - The Plane Gallery
Greetings From Christchurch



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.08 - https://www.webwizforums.com
Copyright ©2001-2026 Web Wiz Ltd. - https://www.webwiz.net