Movement of record

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

i am the beginner of VB.NET. At the vb6 if i want to move the record at the
ado, i can use the following code : adoStudent.movenext.

At the VB.NET how can i do ? If i have a dataset call dsLoginCheck ?
 
WilliamMomo said:
i am the beginner of VB.NET. At the vb6 if i want to move the record
at the ado, i can use the following code : adoStudent.movenext.

At the VB.NET how can i do ? If i have a dataset call dsLoginCheck ?

ADO.Net is still incomplete. You can not navigate through all records using
MovePrevious/MoveNext. You either have to load the whole table completely
into memory (often impossible or inacceptable with thousands of records), or
load all the PKs and execute a Select-SQL using the PK of the "current
record" to navigate.

see also:
http://msdn.microsoft.com/library/en-us/cpguide/html/cpconaccessingdatawithadonet.asp

in particular:
http://msdn.microsoft.com/library/en-us/cpguide/html/cpconcreatingusingdatasets.asp

Better group to ask ADO.Net related (language unrelated) questions:
microsoft.public.dotnet.framework.adonet


Armin
 
WilliamMomo,

Be aware that a datases is a wrapper around datatables which you can compare
with recordsets (although a dataset/datatable is disconnected)

The movenext etc through a datatable in .Net is much easier than it was with
Ado

First to address your table
dim dt as datatable = dsLoginCheck.Tables(0)

dt.rows(0) is the first
dt.rows(0+1) is the next row
dt.rows(dt.rows.count-1) is the last

etc think about it yourself what an endless posibilities you have with this

I hope this helps,

Cor
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

UDTs (as was vb6) 113
Lock record 3
Dataset 2
Updating database in a loop 16
Programmatically creating ADO.NET database 5
select query changing bound controls data 3
Appending strings to integers 4
New to ADO2.net 2

Back
Top