Access - Print button

SantasLittleHelper

Board Regular
Joined
Nov 25, 2016
Messages
77
I currently have a print button on a form but it is currently set to print all records by default. Is it possible to change the button to print only the current record by default?
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
I've never used the Print button on a form. I assume you have a form with continuous record display (shows multiple records on the form, not just one). I would imagine you could create a report that your button would then be able to print. Or for that matter, you could duplicate your form and have the report print the cloned form (but with single record display on the second form). Not entirely sure as I print very rarely but can it be done - almost certainly. You just have to play around with the possible solutions.
 
Upvote 0
Yes, just use some criteria in the open report like ID = Me.ID

I use this in one of my forms. The iPreview and iDiailog are just my variables for those parameters and I process a recordset and produce a report for each ship.
Code:
    stLinkCriteria = "[Ship] = '" & Me.cboShip.Value & "'"
    
    DoCmd.OpenReport stRptName, iPreview, , stLinkCriteria, iDialog
 
Upvote 0

Forum statistics

Threads
1,225,609
Messages
6,185,985
Members
453,333
Latest member
BioCoder84

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top