[AccessD] Count Current Record (Access 2007)

Darryl Collins Darryl.Collins at coles.com.au
Thu Mar 26 23:05:14 CDT 2009


This seems to work in Access 2007 - going to test if it is now backwardly compat with XL2003.

'===================================================
Public Function GetRecordText() As String
    GetRecordText = CStr(Recordset.AbsolutePosition + 1) + " of " & CStr(Recordset.RecordCount)
End Function
'===================================================

also found you can hide the ribbon using

docmd.ShowToolbar "Ribbon",acToolbarNo

Seems to work well for those who are interested.

regards
Darryl.

-----Original Message-----
From: accessd-bounces at databaseadvisors.com [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Darryl Collins
Sent: Friday, 27 March 2009 2:40 PM
To: 'Access Developers discussion and problem solving'
Subject: [AccessD] Count Current Record (Access 2007)

Hi Guys and Gals,

I have been using without issue the follow code on many forms to return the current row number.  Is displays "Record 59 of 250" in the form.  Now in Access 2007 it is returning "#Name?"

=[CurrentRecord] & " of " & [RecordsetClone].[RecordCount]

Clearly it doesn't like something, but I have no idea what.  Any pointers?

regards
Darryl.

This email and any attachments may contain privileged and confidential information
and are intended for the named addressee only. If you have received this e-mail in
error, please notify the sender and delete this e-mail immediately. Any
confidentiality, privilege or copyright is not waived or lost because this e-mail
has been sent to you in error. It is your responsibility to check this e-mail and
any attachments for viruses.  No warranty is made that this material is free from
computer virus or any other defect or error.  Any loss/damage incurred by using this
material is not the sender's responsibility.  The sender's entire liability will be
limited to resupplying the material.


-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com

This email and any attachments may contain privileged and confidential information
and are intended for the named addressee only. If you have received this e-mail in
error, please notify the sender and delete this e-mail immediately. Any
confidentiality, privilege or copyright is not waived or lost because this e-mail
has been sent to you in error. It is your responsibility to check this e-mail and
any attachments for viruses.  No warranty is made that this material is free from
computer virus or any other defect or error.  Any loss/damage incurred by using this
material is not the sender's responsibility.  The sender's entire liability will be
limited to resupplying the material.





More information about the AccessD mailing list