| re: Setting Report Properties at Run Time
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" <smartin108@yahoo.com> wrote in message
news:ne2dnQ2nXK_5mP3eRVn-hQ@giganews.com...[color=blue]
> 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
> <NOSdnb5Ah4lnnf3eRVn-tA@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[/color] |