Link to home
Start Free TrialLog in
Avatar of maysb
maysb

asked on

Problem with MovePrevious() in ASP

I am trying to get MovePrevious() to work in an ASP page...  here is the code that I am using...

sqltxt = "select * from customer"
Set Con = Server.CreateObject("ADODB.Connection")
Con.Open "DSN=Pets;UID=;PWD=;DATABASE=Pets"
Set rs = Server.CreateObject("ADODB.Recordset")
rs.CursorType = adOpenStatic
rs.open sqltxt, con

... then when I try to go to use MovePrevious(), the page stopps running and says that an "Exception occurred" on the line with the MovePrevious() command (rs.MovePrevious()) to be exact.

Any thoughts?

Thanks!
ASKER CERTIFIED SOLUTION
Avatar of thomasdodds
thomasdodds

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of e-Diddy
e-Diddy

..also try this before the execute if thomas suggestions did not fix.

rs.CusrorLocation = adUseClient,

I have had weird problems before with Static Server side cursors.(default)
maysb

You asked to split points between e-Diddy and thomasdodds.
I have reduced the points on this question from 100 to 50 as indicated by your request at Community Support. Please copy the URL and create a new question in this topic area for the other Experts to whom you wish to award points. The title of the question should read "Points for", followed by the Expert's name. In the question itself, you should paste the link to the original question and perhaps a comment stating that the points are for their help with that question. Once you have created the new questions, you can go back to the original, and accept the comment from the Expert for whom you did not create a new question. The Experts will  comment in your new "Points for" question(s), which you then accept and grade to close.
If you have any questions, please don't hesitate to ask.
Thank you.

** Mindphaser - Community Support Moderator **
Avatar of maysb

ASKER

Thanks guys.  Unfortunatly, it was my inability to code that was the problem... not any of this stuff.  Since you were both kind enough to look into this, I will split the points.  ThomasDodds, I am going to give you 50 points for answering and e-Diddy, follow this link

https://www.experts-exchange.com/questions/20528711/Points-for-e-Diddy.html

and submit an answer for your 50 points.

Thanks again.
Avatar of maysb

ASKER

Thanks again!
no problem - sometimes I need the extra eyes too!