| Author |
Topic Search Topic Options
|
ivonda
Newbie
Joined: 20 August 2003
Location: Netherlands
Status: Offline
Points: 19
|
Post Options
Thanks(0)
Quote Reply
Topic: Rowset does not support fetching backward 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
Edited by ivonda
|
 |
stephen
Newbie
Joined: 23 August 2002
Location: United Kingdom
Status: Offline
Points: 33
|
Post Options
Thanks(0)
Quote Reply
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
|
 |
Bunce
Senior Member
Joined: 10 April 2002
Location: Australia
Status: Offline
Points: 846
|
Post Options
Thanks(0)
Quote Reply
Posted: 21 August 2003 at 3:42am |
Great site from a fellow Aussie: 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.
|
 |
ivonda
Newbie
Joined: 20 August 2003
Location: Netherlands
Status: Offline
Points: 19
|
Post Options
Thanks(0)
Quote Reply
Posted: 21 August 2003 at 7:39am |
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?
|
 |
stephen
Newbie
Joined: 23 August 2002
Location: United Kingdom
Status: Offline
Points: 33
|
Post Options
Thanks(0)
Quote Reply
Posted: 21 August 2003 at 2:18pm |
wherever you have
set rs = CreateObject ("ADODB.RecordSet")
|
 |
b_bonnett
Mod Builder Group
Joined: 16 April 2003
Location: New Zealand
Status: Offline
Points: 275
|
Post Options
Thanks(0)
Quote Reply
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
|
|
|
 |
ivonda
Newbie
Joined: 20 August 2003
Location: Netherlands
Status: Offline
Points: 19
|
Post Options
Thanks(0)
Quote Reply
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)
Edited by ivonda
|
 |
b_bonnett
Mod Builder Group
Joined: 16 April 2003
Location: New Zealand
Status: Offline
Points: 275
|
Post Options
Thanks(0)
Quote Reply
Posted: 22 August 2003 at 5:33pm |
If you want a random banner ad, then use Microsoft's Ad Rotator component. Click here for details on how to use it.
Blair
|
|
|
 |