[AccessD] Landscape Form Printing

William Hindman wdhindman at bellsouth.net
Tue Oct 21 18:15:12 CDT 2003


Dale

...maybe I'm missing something here ...your post says you're trying to print
in Landscape ...your code says Portrait?
...on your designated printer, would that make your bottom margin an invalid
setting?

William Hindman
"How can there possibly be liberty and justice for all,
when, in the name of justice, people claim rights to income,
food, housing, education, health care, transportation, ad
infinitum? We can't. Positive rights to receive such things,
absent an obligation to earn them, must violate others' liberty,
by taking some of their income without their consent. They are
really just wishes, convertible into benefits for some only by
employing the government to violate others' rights not to have
what is theirs taken." --Prof. Gary Galles of Pepperdine University

----- Original Message ----- 
From: "Dale Kalsow" <dkalsow at yahoo.com>
To: <accessd at databaseadvisors.com>
Sent: Tuesday, October 21, 2003 4:54 PM
Subject: [AccessD] Landscape Form Printing


> Good Afternoon,
>
> I have the following code in Access XP, behind a button.  I am trying to
print the screen to the default printer in landscape.
>
> Dim rpt As Printer
>
>     Application.Printer = Application.Printers(0)
>
>     With rpt
>         .BottomMargin = 720
>         .Copies = 1
>         .Duplex = acPRDPVertical 'Double sided
>         .PaperBin = acPRBNLargeCapacity
>         .Orientation = acPRORPortrait
>     End With
>     DoCmd.PrintOut acPrintAll, 1, 1, acHigh, 1, True
>     Set Application.Printer = Nothing
>
> I get the error "Object with Block Variable not set " on the .BottomMargin
line.
>
> Does any one know how to fix this?
>
> Thanks in advance!
>
> Dale
>
>
> ---------------------------------
> Do you Yahoo!?
> The New Yahoo! Shopping - with improved product search
> _______________________________________________
> AccessD mailing list
> AccessD at databaseadvisors.com
> http://databaseadvisors.com/mailman/listinfo/accessd
> Website: http://www.databaseadvisors.com
>




More information about the AccessD mailing list