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

Setting Report Properties at Run Time

P: n/a
I'm looking for a work-around to my printing issue. I designed a report
that mimics a form that I am (so far) unable to print (see
<NO********************@giganews.com> ).

I am able to print the report in code but I am not able to do a couple
things that are important to the user. To wit: I need to set the report
FontName and FontSize properties at run time. A97 does not seem to want
to let me to do this.

I tried something like this in my cmdPrint event:

DoCmd.OpenReport "Notes", acViewPreview
Reports("Notes").txtNotes.FontName = "blah blah blah"

and no error is returned, but the report is not affected.

Trying to set the report properties before opening the report fails
saying "...refers to a report that isn't open..."

Has anyone done this?
--
Smartin
Nov 13 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Access 2002 and 2003 have OpenArgs for Reports as well as for Forms. If you
are at that level, you can pass in the FontName and FontSize as string
values in OpenArgs.

Larry Linson
Microsoft Access MVP

"Smartin" <sm********@yahoo.com> wrote in message
news:ne********************@giganews.com...
I'm looking for a work-around to my printing issue. I designed a report
that mimics a form that I am (so far) unable to print (see
<NO********************@giganews.com> ).

I am able to print the report in code but I am not able to do a couple
things that are important to the user. To wit: I need to set the report
FontName and FontSize properties at run time. A97 does not seem to want to
let me to do this.

I tried something like this in my cmdPrint event:

DoCmd.OpenReport "Notes", acViewPreview
Reports("Notes").txtNotes.FontName = "blah blah blah"

and no error is returned, but the report is not affected.

Trying to set the report properties before opening the report fails saying
"...refers to a report that isn't open..."

Has anyone done this?
--
Smartin

Nov 13 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.