Read-only code sections of AppBuilder-generated code

You can make the sections of the AppBuilder-generated code read-only and foldable in the ABL Editor. This ensures that users do not modify the AppBuilder-generated code while editing the ABL procedure (.w) file in the ABL Editor. Editing the AppBuilder-generated code might make the AppBuilder procedure (.w) file corrupt, and display errors when trying to open in the ABL GUI Designer.

The default display color for the read-only code is gray. You can set the display options of AppBuilder-generated code in the ABL Editor using the Editor preferences page. See Editor preferences.
Note: The Find/Replace option will not work with the read-only or auto-generated code of an AppBuilder procedure file. You cannot rename an internal procedure or function name which is part of the auto-generated or read-only code section.

There are two main &ANALYZE directives in an AppBuilder (.w) file: &ANALYZE-SUSPEND and &ANALYZE-RESUME. The &ANALYZE-SUSPEND directive causes the Analyzer to suspend analysis of ABL code. The &ANALYZER-RESUME directive causes the Analyzer to resume analysis. See Code analysis in GUI Designer.

The identifiers that define the read-only rules are the &ANALYZE-SUSPEND and &ANALYZE-RESUME statement directives. When an ABL procedure (.w) file is opened in the GUI Designer, the &ANALYZE-SUSPEND and &ANALYZE-RESUME directives code are parsed to mark the code sections within these directives as read-only and foldable in the ABL Editor.

Here is a list of sample illustrations with the code snippets marking the code section or block within the &ANALYZE directives as read-only or editable: