By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
454,308 Members | 1,929 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 454,308 IT Pros & Developers. It's quick & easy.

Set Report Zoom to 90%

P: n/a
When a report is open in preview mode, you can go to the Zoom button on the
toolbar at the top of the screen, type in a zoom percent different from what
is in the list and the magnification changes to whatever you typed in. When
I open a report in code, I would like to set the zoom to 90%
programatically. There are RunCommand acZoom constants for 75% and 100% but
no 90%. I tried using acZoom90 but get an error message. Can the zoom be set
programatically to 90%? How?

Thanks!

Marie
Nov 13 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
ZoomControl may be undocumented, but its been working for me:

strRpt = "xyz"
docmd.openreport strRpt, acViewPreview
Reports(strRpt).ZoomControl = ZOOMPERCENT

Where ZOOMPERCENT is a public constant declared in a module
Public Const ZOOMPERCENT As Integer = 90

Richard Bernstein
"Marie" <pl****@no.spam> wrote in
news:pf*****************@newsread3.news.pas.earthl ink.net:
When a report is open in preview mode, you can go to the Zoom button
on the toolbar at the top of the screen, type in a zoom percent
different from what is in the list and the magnification changes to
whatever you typed in. When I open a report in code, I would like to
set the zoom to 90% programatically. There are RunCommand acZoom
constants for 75% and 100% but no 90%. I tried using acZoom90 but get
an error message. Can the zoom be set programatically to 90%? How?

Thanks!

Marie


Nov 13 '05 #2

P: n/a
That's cool, Richard.

Looks like it has to be set after the report is open, i.e. Report_Open and
Report_Activate are too early.

Setting ZoomControl to zero achieves a size-to-fit.

Setting ZoomControl to 1 generates an error:
There isn't enough free memory to update the display.
Close unneeded programs and try again
Maybe it's not completely reliable, hence undocumented.

--
Allen Browne - Microsoft MVP. Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Richard Bernstein" <no@spam.com> wrote in message
news:Xn*******************************@69.28.186.1 58...
ZoomControl may be undocumented, but its been working for me:

strRpt = "xyz"
docmd.openreport strRpt, acViewPreview
Reports(strRpt).ZoomControl = ZOOMPERCENT

Where ZOOMPERCENT is a public constant declared in a module
Public Const ZOOMPERCENT As Integer = 90

Richard Bernstein

Nov 13 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.