How do I suppress "Print Macro Definition" (1 Viewer)

rkw12345

New member
Local time
Yesterday, 18:57
Joined
May 21, 2004
Messages
8
To anyone who might know:

I have a macro that calls up 36 different reports, but at the same time, after each report has started to print, it brings up a dialog box "Print Macro Definition".

What I have been doing is cancelling this dialog box because it is not needed.

How can I cause this to be suppressed so I will not have to interact with Access while the reports print?

Thank you!!!
 

ChrisO

Registered User.
Local time
Today, 11:57
Joined
Apr 30, 2003
Messages
3,202
G’day rkw12345 and welcome to the site.

Don’t know much about Macro’s but can you convert the Macro to VBA and copy/paste the code?

Tools/Macro/Convert Macros to VBA

Regards,
Chris.
 

rkw12345

New member
Local time
Yesterday, 18:57
Joined
May 21, 2004
Messages
8
Here it is:


'------------------------------------------------------------
' FC_KG_ADOP_Payment_Report
'
'------------------------------------------------------------
Function FC_KG_ADOP_Payment_Report()
On Error GoTo FC_KG_ADOP_Payment_Report_Err

' 1
DoCmd.OpenReport "01 Payments - Voluntary", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "01 Payments - Voluntary"
' 2
DoCmd.OpenReport "02 Payments - Kin-Gap", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "02 Payments - Kin-Gap"
' 3
DoCmd.OpenReport "03 Payments - FC Relative (basic rate)", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "03 Payments - FC Relative (basic rate)"
' 4
DoCmd.OpenReport "04 Payments - FC - Relative (basic rate) with prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "04 Payments - FC - Relative (basic rate) with prob"
' 5
DoCmd.OpenReport "05 Payments - FC - Relative (basic rate) wo prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "05 Payments - FC - Relative (basic rate) wo prob"
' 6
DoCmd.OpenReport "06 Payments - FC - Relative (specialized rate)", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "06 Payments - FC - Relative (specialized rate)"
' 7
DoCmd.OpenReport "07 Payments - FC - Relative (specializ rate) w prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "07 Payments - FC - Relative (specializ rate) w prob"
' 8
DoCmd.OpenReport "08 Payments - FC - Relative (specialized rate) wo prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "08 Payments - FC - Relative (specialized rate) wo prob"
' 9
DoCmd.OpenReport "09 Payments - FC - Extended Family Home (basic rate)", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "09 Payments - FC - Extended Family Home (basic rate)"
' 10
DoCmd.OpenReport "10 Payments - FC - Ext Family Hm (basic rate) w prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "10 Payments - FC - Ext Family Hm (basic rate) w prob"
' 11
DoCmd.OpenReport "11 Payments - FC - Ext Famly Hm (basic rate) wo prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "11 Payments - FC - Ext Famly Hm (basic rate) wo prob"
' 12
DoCmd.OpenReport "12 Payments - FC - Ext Family Home (specialize rate)", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "12 Payments - FC - Ext Family Home (specialize rate)"
' 13
DoCmd.OpenReport "13 Payments - FC - Ext Fam Hm (specialize rate) w prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "13 Payments - FC - Ext Fam Hm (specialize rate) w prob"
' 14
DoCmd.OpenReport "14 Payments - FC - Ext Fam Hm (special rate) wo prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "14 Payments - FC - Ext Fam Hm (special rate) wo prob"
' 15
DoCmd.OpenReport "15 Payments - Wraparound Program", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "15 Payments - Wraparound Program"
' 16
DoCmd.OpenReport "16 Payments - FC - Foster Home (basic rate)", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "16 Payments - FC - Foster Home (basic rate)"
' 17
DoCmd.OpenReport "17 Payments - FC - Foster Home (basic rate) with prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "17 Payments - FC - Foster Home (basic rate) with prob"
' 18
DoCmd.OpenReport "18 Payments - FC - Foster Home (basic rate) wo prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "18 Payments - FC - Foster Home (basic rate) wo prob"
' 19
DoCmd.OpenReport "19 Payments - FC - Foster Home (specialized rate)", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "19 Payments - FC - Foster Home (specialized rate)"
' 20
DoCmd.OpenReport "20 Payments - FC - Foster Home (specializ rate) w prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "20 Payments - FC - Foster Home (specializ rate) w prob"
' 21
DoCmd.OpenReport "21 Payments - FC - Foster Hm (special rate) wo prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "21 Payments - FC - Foster Hm (special rate) wo prob"
' 22
DoCmd.OpenReport "22 Payments - FC - FFA", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "22 Payments - FC - FFA"
' 23
DoCmd.OpenReport "23 Payments - FC - FFA with prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "23 Payments - FC - FFA with prob"
' 24
DoCmd.OpenReport "24 Payments - FC - FFA without prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "24 Payments - FC - FFA without prob"
' 25
DoCmd.OpenReport "25 Payments - FC - 969 Intensive Services", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "25 Payments - FC - 969 Intensive Services"
' 26
DoCmd.OpenReport "26 Payments - FC - 969 Intensive Services with prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "26 Payments - FC - 969 Intensive Services with prob"
' 27
DoCmd.OpenReport "27 Payments - FC - 969 Intensive Services without prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "27 Payments - FC - 969 Intensive Services without prob"
' 28
DoCmd.OpenReport "28 Payments - FC - Group Home", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "28 Payments - FC - Group Home"
' 29
DoCmd.OpenReport "29 Payments - FC - Group Home with prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "29 Payments - FC - Group Home with prob"
' 30
DoCmd.OpenReport "30 Payments - FC - Group Home without prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "30 Payments - FC - Group Home without prob"
' 31
DoCmd.OpenReport "31 Payments - FC - Guardian", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "31 Payments - FC - Guardian"
' 32
DoCmd.OpenReport "32 Payments - FC - Adoptive Placement", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "32 Payments - FC - Adoptive Placement"
' 33
DoCmd.OpenReport "33 Payments - Shelter Home", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "33 Payments - Shelter Home"
' 34
DoCmd.OpenReport "34 Payments - Unknown or Other", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "34 Payments - Unknown or Other"
' 35
DoCmd.OpenReport "35 Payments - Unknown or Other with prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "35 Payments - Unknown or Other with prob"
' 36
DoCmd.OpenReport "36 Payments - Unknown or Other without prob", acNormal, "", ""
DoCmd.PrintOut acPrintAll, , , acHigh, 1, True
DoCmd.Close acReport, "36 Payments - Unknown or Other without prob"


FC_KG_ADOP_Payment_Report_Exit:
Exit Function

FC_KG_ADOP_Payment_Report_Err:
MsgBox Error$
Resume FC_KG_ADOP_Payment_Report_Exit

End Function


I hope this helps you determine what I can do. Thanks.
 

ChrisO

Registered User.
Local time
Today, 11:57
Joined
Apr 30, 2003
Messages
3,202
Try this: -

Open a new Macro but only use the first command i.e.

Code:
OpenReport  

Report Name	01 Payments – Voluntary
View		Print
If that works OK you can rework the Macro, to remove the lines, or put the report names in a table and use a recordset.

I would recommend the table method because you won’t have to modify the Macro each time a report is added or deleted.

A97 demo attached.

Regards,
Chris.
 

Attachments

  • PrintReportsA97.zip
    19.8 KB · Views: 352

rkw12345

New member
Local time
Yesterday, 18:57
Joined
May 21, 2004
Messages
8
Thank you for the fast reply. I am not sure how to make the module run once I get it setup, but I will try it out.

Again, thanks.
 

AlwinK

New member
Local time
Today, 03:57
Joined
Nov 6, 2006
Messages
1
Solved

The message "Print Macro Definition" only shows up when you use the macro action "PrintOut".
To print a report without any confirmations or boxes only use OpenReport.

Example to open a report and print it directly to PDF:
1 Open the report
2 select File/Pagesetup
3 select tab Page
4 Select Use specific printer
5 choose the printer Adobe Acrobat distiller
6 set your settings using Properties
7 set the output folder to the folder you wish
8 deselect all other options
9 Hit OK 3 times
10 create a macro using Insert/macro
11 Choose the action: OpenReport
12 set the view to Print
13 set the window mode to hidden

Run the macro and enjoy :p
To print more reports in a row add a new line and continue on line 11.
 

rkw12345

New member
Local time
Yesterday, 18:57
Joined
May 21, 2004
Messages
8
Thank you !!!!

This is great. I am now involved with various other projects, and I will be able to incorporate this solution with some of them.

Again, thank you !!!
 

Users who are viewing this thread

Top Bottom