Print just the current record via a button on a form

G

Guest

I have created a form to display my data in a simple name and address table.
I have created buttons to navigate through the records but want to create a
button to print just the current record, ideally with a different layout to
that used on the form.
No matter what I do it always prints all the records. I could select the
page range in the print dialog box but I want it to print just the current
record to make it easy for other to use.
How do I do this?
thanks
Brian
 
G

Guest

You should create a report based on the same source as the form (would have
all the records by default). Then from your form button you would open the
report adding a filter, thus only displaying a single record (you can also
send it directly to the printer).

Take a look at:

http://forums.aspfree.com/microsoft-access-help-18/print-report-for-current-record-19158.html
http://articles.techrepublic.com.com/5100-10877-6160599.html
http://en.allexperts.com/q/Using-MS-Access-1440/Printing-current-record.htm
http://www.databasedev.co.uk/print_form_record.html
 
J

Jeff Boyce

Brian

One approach might be to add your command button and use:
DoCmd.OpenReport "YourReportName",,,WHERE-condition

Check Access HELP for exact syntax. The "WHERE-condition" clause will be
where you specify that the ID field (in the report) needs to match the ID of
the record displayed in your form.

--
Regards

Jeff Boyce
Microsoft Office/Access MVP


Microsoft IT Academy Program Mentor
http://microsoftitacademy.com/

Microsoft Registered Partner
https://partner.microsoft.com/
 

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

Top