PC Review


Reply
Thread Tools Rate Thread

How can I determine my Current Record?

 
 
michaaal
Guest
Posts: n/a
 
      14th Jun 2004
I am going to do an SQL type query on my database based on the Current
Record that is selected.
How can I determine which is the Current Record?

Something like this...?

x = Application.CurrentRecordID


 
Reply With Quote
 
 
 
 
=?Utf-8?B?cHZpY3Rvcg==?=
Guest
Posts: n/a
 
      14th Jun 2004
Assuming that you want to save a reference to the Current Record so you can come back to it later, use the Bookmark property of the Recordset. Code might be something like the following:

Dim vCurRecBookmark as Variant
Dim rsData as DAO.Recordset
'
' Populate rsData using a SQL Query somehow
'
vCurRecBookMark = rsData.Bookmark ' Save Pointer to Current record
'
' Do something that moves current in rsData to another record
'
rsData.Bookmark = vCurRecBookmark ' Resets current to bookmarked record
'
' Note: rsData must be Bookmarkable for this to work.
'

Hope this helps.

Victor






"michaaal" wrote:

> I am going to do an SQL type query on my database based on the Current
> Record that is selected.
> How can I determine which is the Current Record?
>
> Something like this...?
>
> x = Application.CurrentRecordID
>
>
>

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Linking a PDF file of the current record to the current record Angie Microsoft Access External Data 0 3rd Feb 2006 09:08 PM
Find Record action to display a record that is the current record on another for Tom K via AccessMonster.com Microsoft Access Macros 0 31st Oct 2005 07:45 PM
Current Record Count, Previous Record #, Add New Record =?Utf-8?B?Um9iZXJ0IE51c3ogQCBEUFM=?= Microsoft Access Forms 0 15th Feb 2005 08:35 PM
Determine if a corosponding record exist for a master record on a subreport Jasonm Microsoft Access Reports 5 29th Jan 2005 02:59 AM
Determine current sub Chuck Microsoft Dot NET Framework 4 27th Nov 2003 03:08 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:54 PM.