Displaying Print Preview Neatly

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

Guest

I am using a print preview instead of a continuous form to display selected
records with linked images. The user will select a parameter from a combo
box-- region 1, region 2, and so on. My questions are:

1. How to I pass the parameter that the user selected from the combobox to
the query of the report?

2. What event of the combobox should I code to open the report in print
preview?

3. What should I do on the report design so the print preview will be
displayed neatly on the screen without having the user to adjust the preview
frame or moving the horizontal scroll bar to the right or left? I would like
to have the width of the print preview to be the same as the report width
when it is displayed on the screen.

Thanks for any helpful tips.

RT
 
RT:

Taking your questions in order, you can reference the combobox in the report
query by using the FORMS!FORMNAME!CONTROLNAME syntax. This is generally
referred to as Query by Form. The following KB article provides additional
information on how to do this.

http://support.microsoft.com/default.aspx?scid=kb;en-us;304428

While I do not know all the specifics of your setup, generally you use (or
at least I use) the Change event of the combobox to invoke actions. Using
this event, each time the user changes the region the report will be opened
in Print Preview.

Regarding how the report is displayed in Print Preview, you can adjust the
zoom of the report through the Docmd.RunCommand method. There is also a
DoCmd.Maximize method that will allow you to maximize the Print Preview
window.

--
David Lloyd
MCSD .NET
http://LemingtonConsulting.com

This response is supplied "as is" without any representations or warranties.


I am using a print preview instead of a continuous form to display selected
records with linked images. The user will select a parameter from a combo
box-- region 1, region 2, and so on. My questions are:

1. How to I pass the parameter that the user selected from the combobox to
the query of the report?

2. What event of the combobox should I code to open the report in print
preview?

3. What should I do on the report design so the print preview will be
displayed neatly on the screen without having the user to adjust the preview
frame or moving the horizontal scroll bar to the right or left? I would
like
to have the width of the print preview to be the same as the report width
when it is displayed on the screen.

Thanks for any helpful tips.

RT
 
Back
Top