Solved Call Report Page Setup by VBA or Macro

Bounthong

New member
Local time
Today, 15:06
Joined
Feb 28, 2023
Messages
4
Dear Expert,
I want to call report Page Setup (where I can select printer, change paper size, margin, ...), which is normally can be accessed by right mouse click and then select from popup menu. In my case I want to avoid all shortcut keys/popup menu, so would that possible to call Page Setup from my report (let say implement through the command button on the report view).
Thank you.
 
Look at the Docmd.RunCmd acCmdPageSetup
acCmdPageSetup

page.jpg
 
Hi. Welcome to AWF!

You could try something like:
Code:
DoCmd.RunCommand acCmdPrint
Sent from phone...

Edit: Oops, too slow and used the wrong constant. Sorry.
 
Thanks theDBguy and MajP for you quick reply. I have tried with Docmd.RunCommand acCmdPrint, I have got error message 2585 (this action can't be carried out while processing a form or report event). What is your advise?
Thanks
 
Hi,

I have resolved my problem already with another method. I disabled all menus and short cut menu, and created custom ribbons for my purpose instead.

Thanks.
 

Users who are viewing this thread

Back
Top Bottom