Hello!
I hope this message finds you well 馃槃
Lately, I have been having a weird message popping up when exporting my application:

In French, it says "Waiting for printer connection, or cancel the connection".
After investigating doing a step by step debugging, I found out that the issue come from this line in clsDevMode
' Attempt to load the printer object
Set objPrinter = GetPrinterByName(strPrinter)
Namely, looping through all Application.Printers triggers this popup : GetPrinterByName()
It searches for the "Microsoft Print to PDF" printer, but the popup is coming from another one. This is happening because I have a Brother Laser printer that is offline most of the time.
Now, I know this is specific to my setup, I could simply remove this printer, or start it before I export. But this is not very user friendly, especially when I want to print with this printer...
I wonder if it would be possible to get the printer settings without looping through all printers?
In the doc, it seems we could directly get the printer by its name without looping: https://learn.microsoft.com/en-us/office/vba/api/access.printer
If I can find a bit more time, I will try this.
Thank you and have a nice day!
Hello!
I hope this message finds you well 馃槃
Lately, I have been having a weird message popping up when exporting my application:

In French, it says "Waiting for printer connection, or cancel the connection".
After investigating doing a step by step debugging, I found out that the issue come from this line in clsDevMode
Namely, looping through all
Application.Printerstriggers this popup : GetPrinterByName()It searches for the "Microsoft Print to PDF" printer, but the popup is coming from another one. This is happening because I have a Brother Laser printer that is offline most of the time.
Now, I know this is specific to my setup, I could simply remove this printer, or start it before I export. But this is not very user friendly, especially when I want to print with this printer...
I wonder if it would be possible to get the printer settings without looping through all printers?
In the doc, it seems we could directly get the printer by its name without looping: https://learn.microsoft.com/en-us/office/vba/api/access.printer
If I can find a bit more time, I will try this.
Thank you and have a nice day!