How to Create a Keyboard-Activated Save As Button in PDF Forms
Question details
The user wants to add a button to a PDF form that can be focused using the Tab key, activated with the Spacebar or Enter key, and open the Save As dialog with a prepopulated file name based on a form field value.

- Product
- PDF Editor
- Device & OS
- not provided
- Scenario
- Designing an interactive PDF form that requires accessible, keyboard-friendly navigation for saving the completed document.
- Observed behavior
- The user needs the specific trigger settings for the Save As command and a way to prepopulate the default file name, as standard PDF functionality often restricts automated file naming for security reasons.
Ensure you have a professional PDF editor with form creation capabilities and access to button property settings.
Configure a PDF Button to Trigger the Save As Dialog
Set up a button form field with a Mouse Up action that natively responds to keyboard navigation and triggers the standard save prompt.
By default, standard PDF form buttons are keyboard accessible. When a user navigates to a button field using the Tab key, pressing the Spacebar will simulate a click, which triggers the 'Mouse Up' action.
Open your PDF in form editing mode and insert a new Button form field onto the page.
Right-click the button and select Properties, then navigate to the Actions tab.
Choose 'Mouse Up' from the Select Trigger dropdown menu. This ensures the button works correctly when activated by the Spacebar.
From the Select Action dropdown, choose 'Execute a menu item' and click Add. Select 'Save As' from the list of menu items. Alternatively, select 'Run a JavaScript' and enter app.execMenuItem("SaveAs"); in the editor.

Create Interactive PDF Forms Easily with WPS Office
WPS Office provides a comprehensive suite of PDF tools that make designing, filling, and managing interactive forms incredibly straightforward, allowing you to add buttons and actions without writing complex code.
- 1. Open your PDF document: Launch WPS Office and open your existing PDF file or create a new one.
- 2. Access form tools: Navigate to the Form tab on the top ribbon to access all interactive PDF form controls.
- 3. Insert a button: Select the Button tool, draw it on your document, and double-click to open its properties.
- 4. Assign an action: Under the Actions tab, assign standard commands like submitting, resetting, or executing menu items.

Frequently Asked Questions
Why doesn't the PDF Save As dialog automatically use my field value for the file name?
Standard PDF viewers restrict automated file naming and silent saving during a Save As action to prevent malicious scripts from overwriting system files. The user must manually confirm the file name and location.
How do I select a PDF form button using my keyboard?
Users can navigate through interactive PDF fields, including buttons, by pressing the Tab key. Once the desired button is highlighted (focused), pressing the Spacebar activates its 'Mouse Up' action.
Can I assign a custom global keyboard shortcut to a PDF button?
Directly assigning global, document-wide keyboard shortcuts to specific form buttons requires advanced document-level JavaScript and is often limited by the specific PDF reader being used. Relying on the standard Tab order is the recommended approach for accessibility.




