Fix Bookmark Not Defined Error in a Word IF Field
Question details
The user needs to resolve a 'Bookmark Not Defined' error that occurs when utilizing an IF field linked to a legacy drop-down form field, despite the referenced bookmark existing in the document.

- Product
- Word Processing
- Device & OS
- not provided
- Scenario
- Creating dynamic conditional text using IF fields combined with legacy drop-down form fields.
- Observed behavior
- The document displays a 'Bookmark Not Defined' error instead of evaluating the conditional logic and displaying the expected output text.
Ensure you have field codes toggled on (by pressing Alt+F9) so you can directly view and edit the underlying syntax rather than the resulting error message.
Correct the REF Syntax and Rebuild the IF Field
Rebuild the field code properly using Ctrl+F9 to insert functional boundaries and ensure the reference command uses 'REF' instead of 'REV'.
The 'Bookmark Not Defined' error in this scenario typically happens for two reasons: typing the curly brackets manually instead of letting the software generate functional field braces, or utilizing incorrect reference codes. Rebuilding the code step-by-step guarantees it acts as a functional field.
Double-click your legacy drop-down form field to open the Drop-Down Form Field Options. Note the exact text in the 'Bookmark' field (e.g., ddsm1).
Press Ctrl+F9 on your keyboard to insert the outer field boundaries { }. Do not type the curly brackets manually.
Inside the outer braces, type 'IF ' (with a trailing space). Then, press Ctrl+F9 again to generate a nested set of braces.
Inside the nested braces, type 'REF ddsm1' (replace ddsm1 with the bookmark name you verified earlier). Make sure you use 'REF' and not 'REV'.
Click outside the nested braces but remain inside the outer braces. Type your conditional logic, for example: = "Car" "Applause" "Silence".
Once your code reads { IF { REF ddsm1 } = "Car" "Applause" "Silence" }, highlight the entire field code and press F9 to update it. Press Alt+F9 to toggle off field codes and view the result.

Create Conditional Text Fields Easily with WPS Writer
WPS Writer offers native support for complex field codes, legacy forms, and bookmarks, allowing you to build dynamic and responsive documents without encountering frustrating syntax errors.
- 1. Open your document: Launch WPS Writer and open the document containing your drop-down fields.
- 2. Access Field settings: Navigate to the 'Insert' tab, select 'Quick Parts', and click 'Field' to securely manage conditional rules.
- 3. Manage Bookmarks: Use the 'Insert' > 'Bookmark' functionality to visually track and edit existing drop-down references.
- 4. Toggle and Update: Use Alt+F9 to reveal your codes, make syntax adjustments, and press F9 to apply updates instantly.

Frequently Asked Questions
Why does typing the { } brackets manually cause a Bookmark Not Defined error?
Manually typing curly brackets { } inserts them as standard text rather than specialized field boundaries. Word processing software requires you to press Ctrl+F9 to insert functional field boundaries, which instructs the program to interpret the enclosed text as an executable command.
How do I make my IF field update automatically when I choose a different drop-down item?
To force an automatic update, double-click the legacy drop-down form field to open its properties, and check the box that says 'Calculate on exit'. When you change the drop-down selection and tab out of the field, the IF field will refresh its result automatically.
What is the difference between REF and REV in field codes?
REF is the standard reference command used to insert the text represented by a bookmark. REV is not a valid field code for referencing drop-down bookmarks in this context, which is why using it will result in calculation errors or 'Bookmark Not Defined' messages.




