Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Reports / Printing / January 2007

Tip: Looking for answers? Try searching our database.

resize of report preview

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Andreas - 19 Jan 2007 14:20 GMT
I call a preview of my report from within a form with the use of acpreview
option.
The report appears with default preview option "fit" which is very small.
How can I make it automatically apear larger or at least make the containing
window autoresize after I select another zoom level. I don't mind selecting
this myself but I want the window to resize itself accordingly
Al Campagna - 19 Jan 2007 16:13 GMT
Andreas,
   Place this code right after the OpenReport method.
       DoCmd.OpenReport "YourReport, acViewPreview
       DoCmd.RunCommand acCmdZoom75
   See RunCommand Method Constants in Help, for all the available Zoom values.

Signature

hth
Al Campagna
Candia Computer Consulting
Microsoft Access MVP - Candia, NH USA
http://home.comcast.net/~cccsolutions

"Find a job that you love, and you'll never work a day in your life."

>I call a preview of my report from within a form with the use of acpreview option.
> The report appears with default preview option "fit" which is very small. How can I make
> it automatically apear larger or at least make the containing window autoresize after I
> select another zoom level. I don't mind selecting this myself but I want the window to
> resize itself accordingly
Andreas - 19 Jan 2007 16:34 GMT
Yes, that would just set the zoom level.
More important to me is how to change the window size because it is always
very small. I could change the zoom manually but you need much more time to
resize the coordinates of the window.

> Andreas,
>    Place this code right after the OpenReport method.
[quoted text clipped - 10 lines]
>> mind selecting this myself but I want the window to resize itself
>> accordingly
Marshall Barton - 19 Jan 2007 16:31 GMT
>I call a preview of my report from within a form with the use of acpreview
>option.
>The report appears with default preview option "fit" which is very small.
>How can I make it automatically apear larger or at least make the containing
>window autoresize after I select another zoom level. I don't mind selecting
>this myself but I want the window to resize itself accordingly

This kind of operation can be done in the form's code right
after the OpenReport line:

DoCmd.OpenReport  . . .
DoCmd.Maximize  'or DoCmd.MoveSize . . .
RunCommand acCmdZoom150  'or acCmdFitToWindow

Check VBA Help for RunCommand acCommand constants to see the
other builtin zoom factors.

Signature

Marsh
MVP [MS Access]

Andreas - 19 Jan 2007 16:52 GMT
Ok, its:
DoCmd.RunCommand acCmdZoom100
DoCmd.MoveSize 6000, 0, 14000, 30000

Exactly what I wanted.
Thanks to al

>>I call a preview of my report from within a form with the use of acpreview
>>option.
[quoted text clipped - 14 lines]
> Check VBA Help for RunCommand acCommand constants to see the
> other builtin zoom factors.
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.