Feature Summary
The WPS Macro Editor is a built-in automation programming tool in WPS Office that supports the JS language. It helps users automate document processing by writing scripts, greatly improving office productivity.
Feature Description
| Feature Dimension | Description |
|---|---|
| Membership Restriction | No membership restriction |
| Version Restriction | No version restriction |
Operation Steps
Opening the JS Macro Editor
Function Entry
"Tools" tab → "Developer Tools" tab → "WPS Macro Editor" button
- Click the Developer Tools button in the Tools tab
- Enter the Developer Tools tab and click the WPS Macro Editor button
- In the Macro Editor, click "Insert" → "Module" at the top
- Write JavaScript code in the JS module


FAQ
Q1: Can I switch to the VBA editor in WPS for Mac?
- Solution: Not currently supported. WPS for Mac currently only supports the JS editor. You can choose to rewrite the macro in the JS editor according to JavaScript code requirements.
Q2: Unable to save macro code
- Solution: Documents containing macros must be saved in a macro-enabled format. WPS Writer documents need to be saved in the
.docmformat; files in the.docxformat cannot save macro code. You can save the file in the.docmformat using Save As.
Notes
- File Format Requirements: Documents containing macros must be saved in a macro-enabled format (
.docm,.wpm,.xlsm,.et, etc.). Standard formats cannot save macro code. - Security Risk: Avoid executing macro script files from unknown sources to reduce security risks.