|
GPP2 EX2 Editor
Access: Open this function from the following location:
-
Run the GPP2_EX2_Editor.exe from your Program folder:
...\Program Files\Cimatron\2026.0\Program\
Open the appropriate .EX2 file in the post2 folder.
...\ProgramData\Cimatron\Cimatron\2026.0\Data\It\var\post2
This tool is used by GPP2 developers to write EX2 programs in a special dedicated programming language, which is described in the GPP2 Language Reference Manual. This EX2 program file is compiled, using the EX2 Editor, to create a DX2 file, which is executed by GPP2.
The EX2 Editor dialog is displayed:
|
The EX2 Editor contains the following sections: Toolbar Buttons To use this dialog see the Interaction. |
Interaction
InvokeInvoke this editor and create a new file (File > New) or browse to open an existing .EX2 file.
The GPP2 EX2 or DF2 files are located in the following folder:
...\ProgramData\Cimatron\Cimatron\2026.0\Data\It\var\post2
Write/edit the EX2 post program file.
If required, see the explanations on the following sections of the EX2 Editor:
Compile ( ) the EX2 file to create a DX2 file, which is executed by GPP2.
Toolbar Buttons
The following toolbar buttonstoolbar buttons appear in the EX2 Editor:
|
Standard file toolbar buttons:
|
||||||||
|
Standard edit toolbar buttons:
|
||||||||
|
Standard undo / redo toolbar buttons:
|
||||||||
|
Find. |
||||||||
|
Compile EXF. This saves the EX2 program file and compiles it to create a DX2 file, which is executed by GPP2. |
||||||||
|
Hide / Show the Console Log pane. |
||||||||
|
Open the DEF Editor. |
||||||||
|
Bookmark buttons:
|
||||||||
|
Hide / Show the Marks Pane. |
||||||||
|
Toggle a comment. This toggles the currently highlighted line between a comment and non-comment status. |
||||||||
|
Comment Block. Convert a block of highlighted text into comments. |
||||||||
|
Remove the comment status of a block of highlighted comments. |
||||||||
|
Jump to line number. Enter a line number and press Enter. If the line number exists in the currently open program, the appropriate line is displayed and highlighted. |
||||||||
|
Display the Cimatron Corporate web page. |
Editor Pane
The Editor Pane displays the EX2 post program file and is used to edit the program.
Below are some editing examples to demonstrate the use of the editor.
Jump to Line #
An example of using the Jump To Line # button. Enter the required line number and press Enter.
The appropriate line, if it exists, is displayed and highlighted.
Whenever any change is done to the post program, [***** Not Compiled *****] is displayed in the title bar to inform you that the post needs to be compiled. In this case, the semicolon (;) at the end of the line has been deleted.
Note: If you attempt to compile the post ( ) when it contains grammatical errors, [ Not Compiled ] is displayed in the title bar and an appropriate message is displayed in the Console Log enabling you to correct the problem.
Assisted Editing
When editing a post program, the EX2 Editor automatically recognizes commands and variable names and assists you by converting commands to upper case and displaying appropriate variable options.
Place the cursor at the beginning of an empty line and type the word "output".
Notice that before you complete the word, the letters are in lower case. |
Once the word is completed it changes to uppercase and its color turns dark blue. GPP2 automatically recognizes commands and variable names (if typed correctly!) and changes their appearance. This is a nice way to make sure you have no typing errors. |
|
|
Continuing the above example - after a space, type the letter "X". Press the CTRL + SPACE BAR keys.
A popup window is displayed, containing a list of all the variables. The cursor is placed on the first variable that starts with the letter (or string) you typed. |
Select any of the variables in the list and it replaces the letter you typed with the selected variable. This ensures that the correct variable name is entered, without you having to remember all the variables. |
|
|
Comment Block
Convert a block of highlighted text into comments.
Select a block of text to be converted into comments and press the |
All the selected lines (including the highlighted line where the cursor is currently positioned) are converted to comments with one single command. |
|
|
Note: To remove the comment status from a block of comments, select the appropriate block press the toolbar button.
Toggle Comment
Toggle a comment. This toggles the currently highlighted line between a comment and non-comment status.
Highlight the appropriate line and press the |
The highlighted line where the cursor is currently positioned is toggled. In this case, notice the following:
|
|
|
Bookmarks
The Bookmarks buttons are used to create, navigate through and clear all bookmarks in the post program.
Highlight the appropriate line and press the |
Use the Next |
|
|
Marks Pane
Hide / Show the Marks Pane by toggling the toolbar button.
The Marks Pane lists all the predefined sections of an EX2 program file in alphabetical order. These include, the header, GPP procedure names, debug flags, block titles, etc.
The Marks Pane is used to navigate the EX2 program file. Select an item in the Marks Panes, and if it appears in the current EX2 program file, it is highlighted in the Editor Pane.
Example Use:
Select an item in the Marks Pane.
The first occurrence of the relevant string (if it exists) in the program is highlighted in the Editor Pane.
Repeated selections of the same item in the Marks Pane, will highlighted subsequent occurrences of the same string (if they exist) in the program. After the last occurrence, the first occurrence is highlighted again.
If the item selected in the Marks Pane does not exist in the program, nothing happens.
Note: The Marks Pane list is composed of the entries in the following files from the \Cimatron\Program\ folder:
-
gpp2-blocks.txt
-
gpp2-marks.txt
Console Log
Hide / Show the Console Log pane by toggling the toolbar button.
The Console Log displays messages informing you of successful or unsuccessful compilation results.
Successful Compile
Successful compilations are displayed in green and inform you that the dx2 file has been created successfully:
Failed Compile
Unsuccessful compilations are displayed in red. In this case the following occur:
In unsuccessful compilations, the following occurs:
-
The Console Log displays the problematic line in the program file and also the nature of the problem, to help you to correct it.
In this example, line 535 is displayed in the Console Log. The second line states the specific cause of the failed compilation - the semi-colon at the end of the line is missing. -
The problematic line is highlighted in the Editor Pane for correction.
-
The title bar informs you that the compile failed.
|