customizing print button

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi.
I have a print button on a form that will print the active form.

the only thing is, is that the form margins need to be set to .5 all around
inorder for it to print on one page. How can I customize the print button to
have custome margin settings or even fit to page would work?

Thanks,
Jessie
 
would you want to be printing a report and not a form? ...if you actually are trying to print a report, then you can adjust that in your page settings of the report.
 
Forms aren't really intended to be printed. Can you create a report instead,
which will give you far more control over things like margins?
 
yeah i could try that if there is no way to print the form as it is.

if i need customized margins, how would i do it in reports?
 
yeah i could try that if there is no way to print the form as it is.

if i need customized margins, how would i do it in reports?

You can print the form, as a report.
On the main database folder, right-click on form name and select Save
as Report.
Open the new report in design view and click on
File + Page Setup + Margins.
Set the margins to whatever you need.
Print the report.

You can restrict the records using the Where clause argument of the
OpenReport method, just as you would any other report:
Add a command button to your form. Code it's Click event:
DoCmd.OpenReport "NewReportName", acViewPreview, , "[RecordID] = " &
Me![RecordID]

The above assumes each record has a unique prime key field of Number
datatype.

If the field is a Text datatype, then use:
"[RecordID] = '" & Me![RecordID] & "'"

Change RecordID to whatever the actual name is of your prime key
field.
 

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

Back
Top