Solved

ADO get current record position

Posted on 2004-03-26
4
408 Views
Last Modified: 2008-02-01
i 'm able to write
adodb.recordset.absoluteposition...

how do i read the current position of record without using variable?
0
Comment
Question by:ill
  • 2
  • 2
4 Comments
 
LVL 11

Expert Comment

by:Slimshaneey
ID: 10685524
Please elaborate???

You can just write to the asp page by
response.write recordsetname.absoluteposition
0
 
LVL 12

Author Comment

by:ill
ID: 10685725
Set db = Server.CreateObject("ADODB.Connection")
db.Open (Session("mydb") )
Set rs = Server.CreateObject("ADODB.Recordset")
set rs= db.execute ( " select * from users")

do while not rs.eof
      response.write ( rs.absoluteposition&"<br>")   'returns -1 for all records
      rs.movenext
loop
0
 
LVL 11

Accepted Solution

by:
Slimshaneey earned 50 total points
ID: 10685740
Ah...
Stick this line in before the opening of the recordset:
db.Cursorlocation = 3
0
 
LVL 12

Author Comment

by:ill
ID: 10685840
uff, so that's it...
thanks
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…

791 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question