Preview - Export to PDF is grayed out.... Use to work regardless of Pdf on Catalina

I fill out forms (mark up) using Preview

When I hit save, all of my mark ups disappear for some reason

My work around on Catalina OS was to click "Export to PDF" I would get a pop up with several options on how to save the pdf and boom.... PDF would save perfect.


On Ventura OS

The Export to PDF button is grayed out.... WHY?

Work around is to click print and click Save as PDF... but you don't get the box with options like Export to pdf when its not grayed out....


Is there a way to disable whatever "efficiency" option that was created and just get the Export to PDF button to work whenever I want it to work?


I know the system is seeing a pdf, and greys it out...

I need to system to take a chill pill and let ME decided with this options....


Any way to modify that, or create an automation with Automator?

iMac 27″, macOS 10.15

Posted on Jun 15, 2023 6:04 PM

Reply
5 replies

Jun 16, 2023 8:11 AM in response to 847Electric

If you want to flatten your PDF so no annotations (e.g. markup) are accessible to others, then your only real option on Ventura is to Print… PDF > Save as PDF.


I have an IRS tax form here that its PDF v1.7 and created by Adobe's Livecycle Designer on Windows. If I start to fill in the form, I see that Export as PDF is grayed out. If I highlight some text (annotation), fill in a few fields in the form and then Print… > PDF > Save as PDF, the resulting PDF will not allow me to edit the annotations, or alter any [un]filled form fields. Seems like that is your goal for any recipient of the PDF.


What is past is not necessarily prologue between Apple operating systems and why that Export as PDF is gray I can't say, but suffice to say it is not an option any more in Ventura.


Preview is not a clone of the more capable Adobe Acrobat Reader DC, and will not handle every PDF consistently that you open in it.

Jun 16, 2023 10:52 AM in response to 847Electric

I do have an AppleScript that flattens PDFs without using Preview… It just prompts for the PDF to flatten and then exports that PDF flattened with a "_flattened" suffix to the original PDF location. This does essentially the same thing as the Print panel PDF > Save as PDF.


Launch Apple's Script Editor via Dock > Launchpad > Other > Script Editor. Click the Desktop in the Favorites sidebar, and click New Document.


Copy/paste the following code into the Script Editor, click the compile (hammer) tool, and the click run.


use framework "Foundation"
use framework "AppKit"
use framework "PDFKit"
use AppleScript version "2.4"
use scripting additions

property SUFFIX : "_flattened"
property NSString : a reference to current application's NSString
property NSURL : a reference to current application's NSURL
property PDFDocument : a reference to current application's PDFDocument
property NSDictionary : a reference to current application's NSDictionary
property NSPrintInfo : a reference to current application's NSPrintInfo

set thisPDF to POSIX path of (choose file of type "com.adobe.pdf" default location (path to desktop) without invisibles) as text

set basename to (NSString's stringWithString:thisPDF)'s stringByDeletingPathExtension()
set basename_sfx to basename's stringByAppendingString:SUFFIX
set outPDF to basename_sfx's stringByAppendingPathExtension:"pdf"
set outURL to NSURL's fileURLWithPath:outPDF

set inURL to NSURL's fileURLWithPath:thisPDF
set pdf to PDFDocument's alloc()'s initWithURL:inURL

set {{x, y}, {w, h}} to (pdf's pageAtIndex:0)'s boundsForBox:(current application's kPDFDisplayBoxMediaBox)
set pdict to (NSDictionary's dictionaryWithObject:outURL forKey:(current application's NSPrintJobSavingURL))'s mutableCopy()
pdict's setObject:(current application's NSPrintSaveJob) forKey:(current application's NSPrintJobDisposition)
pdict's setObject:outURL forKey:(current application's NSPrintJobSavingURL)
set printInfo to NSPrintInfo's alloc()'s initWithDictionary:pdict

printInfo's setVerticalPagination:(current application's NSPrintingPaginationModeAutomatic)
printInfo's setJobDisposition:(current application's NSPrintSaveJob)
printInfo's setTopMargin:36.0
printInfo's setBottomMargin:36.0
printInfo's setLeftMargin:36.0
printInfo's setRightMargin:36.0
printInfo's setPaperSize:(current application's NSMakeSize(w, h))

set printOp to pdf's printOperationForPrintInfo:printInfo scalingMode:0 autoRotate:false
printOp's setShowsPrintPanel:false
printOp's setShowsProgressPanel:false
printOp's runOperation()

return


I would visit the Script Editor's File menu and save this AppleScript. On the Save panel, set the File Format to Text which will set the Save As: extension to AppleScript. I called my flatPDF.applescript. Once saved, you can double-click this to open it, then run it, or subsequently, you can press option+Save As… and change the File Format to any of Script, Script Bundle, or Application and save it. These can be run with a double-click from the Desktop.


Tested: macOS Ventura 13.4 with a PDF form and applied highlight annotation.

Jun 16, 2023 5:33 AM in response to VikingOSX

It saves a marked up PDF....

If I email this to my customers, and they open it on a windows machine with adobe

All my mark up on the document disappears.


I need to create a finalized PDF document

Meaning all the mark up becomes part of the document and you can't edit it anymore.

So when I email it, the document remains unchanged.


In the Catalina OS, you could achieve this by clicking Export to PDF under the file button

In the Ventura OS, Export to PDF is greyed out....

The only work around I found was to click print, then at the bottom click Save as PDF


Not sure what the difference is between

Save as PDF

Export as PDF


I think this is a bug,

I don't want the OS making decisions on when I can finalize a PDF

I'd like the Export to PDF to work the same it did in Catalina.


At the end of the day, I want my customers not to look at me weird or like I have a magic eraser causing the info on the pdfs to disappear.

Jun 16, 2023 9:14 AM in response to VikingOSX

Exactly,


Preview does an amazing job with all my PDF’s…. Most the times I use text boxes from the mark up tool, fill everything out, nice font….


It’s just exporting or saving (flattening) the pdf that’s changed between Operating Systems….


Not sure what the purpose of “if” statements behind the scenes controlling when I can use export to pdf (grey)

I’m sure someone had a good reason, or it’s a glitch…. As of it changes my workflow and added a lot of anxiety trying to figure out how to flatten the pdf again.


I need to learn Apple Scripts and see if there’s a way to automate my work load, but for now, I wish Apple would make the export to pdf work the same as It did in Catalina 🥴😁


thanks for the help 🫡

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Preview - Export to PDF is grayed out.... Use to work regardless of Pdf on Catalina

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.