Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RecNo question

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
Coming from VFP I have'nt be able to find a similar function that can report back a integer of the current record number in a database. I see there is another post, can anyone help please

Much obliged

David
 
If you are using Paradox then just use the name of your source file followed by dataset followed by RecordNumber.. something like this

srcMySource.DataSet.RecordNumber;

this will return an integer representing the number of records in the Paradox table
 
The database doesn't matter. Each dataset has a property RecordCount not RecordNumber >:-<.
The only fact you have to care about is that RecordCount returns the number of selected records. After defining a Filter you will get the numer of records in that filter !

Using a TQuery the RecordCount property may be wrong, but don't ask my why !
 
Is there also somehow I can jump to a record number. I.e. if there are 10 records and I want to jump to the 5th record is there command for that.
Also when you create a new record using the dbnavigator bar I want to put the current record position in a field when a new record is created. This will be unique and following in sequence from the last one.

Much Obliged
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top