Use WPS Macro Editor through 4 how-to topics, all available without membership, and jump from the index to the task you need.
How-to Index
| No. | Topic | Membership Requirement |
|---|---|---|
| 1 | 1. Open the JS Macro Editor | Free |
| 2 | 2. Insert and edit a JS module | Free |
| 3 | 3. Set JS as the default development environment | Free |
| 4 | 4. Save a document that contains macros | Free |
How-to Guide
1. Open the JS Macro Editor
Entry path: Tools tab → Developer Tools → macro editor-related button
- Open WPS Writer.
- Click Developer Tools under Tools.
- In the developer-related area, open the macro editor entry.
- Enter the editor window and get ready to insert a JS module or edit code.
Success Criteria
- Interface result: The macro editor window opens.
- What you can do next: You can see menus related to inserting modules and editing code.
Tips While Using
- Common mistake: If another macro development environment opens first, continue with the next topic to switch to the JS module workflow.
2. Insert and edit a JS module
Entry path: Top menu in the macro editor → Insert → JS Module
- In the macro editor, click Insert on the top menu bar.
- Select JS Module.
- Enter JavaScript code in the new JS module.
- Continue adding or revising the script as needed.
Success Criteria
- Interface result: A JS module appears in the editor.
- What you can do next: You can type, revise, and save code in the module.
Tips While Using
- Common mistake: Make sure you add a JS module instead of writing code in the wrong module type.
3. Set JS as the default development environment
Entry path: File → Options → View
- Click File.
- Open Options.
- Go to the View tab.
- Select Default JS Development Environment and save the setting.
Success Criteria
- Interface result: The related option is selected and saved.
- What you can do next: The JS macro workflow opens first when you return to developer tools.
Tips While Using
- Common mistake: If the setting is not saved, the default environment will not change.
4. Save a document that contains macros
Entry path: File → Save As
- After finishing the macro code, click File.
- Select Save As or a related save command.
- In the file type list, choose a macro-enabled format such as
.docm. - Save the file and reopen it to confirm that the macro content is still there.
Success Criteria
- Interface result: The file is saved in a macro-enabled format.
- What you can do next: After reopening the file, you can still view or continue editing the macro code.
Tips While Using
- Common mistake: The
.docxformat does not retain macro code.- Environment note: Different document types may require different macro-enabled formats.