Tech Tip: 4D v6.5 Syntactical Help
PRODUCT: 4D | VERSION: | PLATFORM:
Published On: July 9, 1999
Your current browser may not allow you to download the asset. We recommend Mozilla Firefox or Google Chrome.
The new syntactical help system consists of:
- Viewing the syntax of 4D commands in the Explorer.
- Viewing the syntax of 4D commands in the method editor.
- Inserting 4D commands, optionally with their syntax, directly into methods.
- Viewing syntax errors directly in the method editor window.
Viewing the syntax in the Explorer
Choose the Commands tab in the Explorer, then click on any command to view its syntax. The preview area (if it is visible) will display the command's syntax, a brief description of the parameter(s), as well as the page of the Language Reference manual where the command is described in full detail.
Viewing the syntax in the method editor
- Select a command in the Command list. The command will be inserted into your method at the current cursor position. The command and its syntax will also be displayed in the new syntax display area in the method's header.
- Enter or select a command in the method window and press the Enter key. The command and its syntax will be displayed in the new syntax display area in the method's header.
Inserting 4D commands directly into methods
To insert a command with its syntax, drag and drop it from the Explorer into the method window:
By default, the command is inserted with its syntax. If you want to drag and drop a command without the syntax, hold down the Alt (Windows) or Option (Mac OS) key.
Viewing and inserting a command's syntax are only possible if the 4D Help file is present in your disk.
- Mac OS: the 4D Help file must be placed in your system's Preferences:4D folder or in the 4D application's folder.
- Windows: the 4D Help.RSR file must be placed in the Windows\4D folder or in the 4D application's folder.
Viewing syntax errors
Syntax errors are now displayed directly in the Method Editor's window. 4D verifies the syntax when a line of code or the entire method is validated. Validating the syntax of a line of code is done automatically when the cursor leaves the line (if you have clicked on another line or hit the Return key). You can also validate a line of code (without going to the following line) by hitting the Enter key.
Validating the entire method is done automatically when you save or close the window. You can also force the validation of the method by pressing Ctrl+Enter (Windows) or Command+Enter (Mac OS).
4D checks each line's syntax and/or the structure of instructions (If... End if, etc.). When an error is detected, a message is written in the syntax display area at the top of the method's window and 4D highlights the line of code that contains the error.