Navigating in source files

The JCL Editor provides various ways to navigate to and from variable declarations, even when a variable is declared in a different file.

Procedure

  • To jump to the location of the next or previous language element, use the Go To > Next Element (Ctrl+Shift+Down) and Go To > Previous Element (Ctrl+Shift+Up) actions.
  • To navigate in a JCL program from a PROC parameter value of an EXEC statement, a data set name, or a qualified data set member name, do one of the following actions:
    • Right-click the language element, and select Open Declaration from the menu.
    • Position the text cursor on language element and press the F3 key.
    • Hover the cursor over the language element, hold down the Ctrl key, and click.
    If the declaration is in the same file as the reference, the editor navigates to the declaration in the same editor. If the declaration is in a collapsed region, the region is expanded. If the reference is in another file and the location of the file can be determined, the source file is opened in a new instance of the editor.
  • To open the Outline or Properties view for the file that is open in the editor, select Show In > Outline or Show In > Properties.
  • To navigate the annotations in the editor, use the Next Annotation (Ctrl+.) and Previous Annotation (Ctrl+,) actions. The types of annotations visited by these actions can be configured on the Annotations page. To access this preference, click General > Editors > Text Editor > Annotations or use the menu on the toolbar.
  • To jump to the editor location of your most recent text change, do one of the following actions:
    • Click Navigate > Last Edit Location.
    • Press Ctrl+Q.
  • To navigate to a specific line number, select Go to Line and type the line number in the window that opens.
  • When you use another view, such as the Outline view, a navigation history entry is created. To jump to the previous editor locations visited by these navigation commands, use the Back (Alt+Left) and Forward (Alt+Right) actions. You can also use the left arrow (left arrow) icon to go back to a previous location and the right arrow (right arrow) icon to move forward. These icons are in the menu bar.

Using the JCL Outline view

When you open a file in the editor, an outline of the file opens in the Outline view. You can expand or collapse file divisions, sort file divisions by name, or filter file divisions by name.

About this task

The divisions in a JCL file are identified by icons in the Outline view:
Icon Outline element
DD statement icon DD statement
EXEC statement icon EXEC statement
JOB statement icon JOB statement

Procedure

  • To expand and collapse sections in the Outline view, click Expand outline or Collapse outline next to the program section you want to expand or collapse. When you place the cursor on a line in the editor, the outline expands or collapses the corresponding node.
  • To sort sibling nodes in the outline in ascending order by name, click Sort elements by name toolbar button.
  • To hide parts of the JCL file according to their name:
    1. Select Filters from the drop-down menu.
      The JCL Element Filters window opens.
    2. Type a name pattern in the field.
      You can use the * and ? wildcard characters in the filter string. Separate multiple filter strings with commas.
    3. Click Ignore case to match strings in upper, lower, or mixed case.
    4. Click OK.
      The Outline view hides any JCL elements that match the filter strings entered.
    5. To show any of these filtered elements, select Filters again, delete the filter strings from the field, and click OK.

Navigating a source file with quick outline

Open a quick outline to see the structure of COBOL, JCL, and PL/I files and navigate in files.

About this task

The quick outline opens on top of the COBOL Editor, JCL Editor, and PL/I Editor. It provides a view of the outline of a source file and tools for navigating in the file.

Procedure

  1. To open the quick outline, click Navigate > Quick Outline or press Ctrl+O.
    The quick outline opens on top of the editor. It contains a search filter and an outline of the content of the editor.
  2. To filter the content of the quick outline, type the text that you want to show in the filter.
    Elements that contain matching text and their ancestors are shown in the outline tree. The first matching element is selected in the outline.
  3. To close the quick outline and navigate to the selected element in the source file, press Enter or double-click the element.