Code Explorer
Code Explorer displays an overview of the current source. A treeview displays a composition of all the major source elements in that file.
Use the Code Explorer to:
- Review the contents and composition of your source files.
- Navigate around your source file.
- Select elements of your source file for modeling and editing.
- Manipulate the order of object declarations in your source files.
Source Code Composition
The Code Explorer treeview displays the composition of the file currently being edited in the Code Editor or the Visual Designer. Each tree item represents some element of code in the file. Different types of code elements are represented by different icons in the tree.
Below is a list of the different element types and their icons:
- Class declaration
- Method declaration (i.e. Procedure or Function)
- Property declaration
- Object declaration
- Use statement
- Enum_List
- Constant declaration (Define or #Replace)
- Struct declaration
- Import_Class_Protocol
- ActiveX resource
- Entry_Item statement
- External_Function declaration
- To Do Items
- Web Property
- Published Web Method
Legacy Items:
- Entry_Item list (used in legacy list and grid classes)
- Legacy Menu command (i.e. DFCreate_Menu)
Code elements such as objects or classes that may contain other code elements are represented in the treeview using nested tree items. Expand a tree item to display the list of nested code elements.
You can filter which code element types will be displayed in the Configure Studio dialog. You can activate the Configure Studio dialog by selecting Configure Studio from the Tools menu or by selecting Configure Code Explorer from the Code Explorer's context menu.
Source Element Selection
Code Explorer can be used to coordinate other Studio views to the current file. Below are some common uses of the Code Explorer for code navigation and selection:
- If you activate the Object Properties panel, then select an object item in the Code Explorer, the object properties for the object you selected are displayed.
- If you have the DDO Explorer active, then selecting any object that contains a DDO structure in the Code Explorer will cause that DDO structure to be displayed in the DDO Explorer. This technique allows you to edit different DDO Structures when a view (such as a dbTabView) contains more than one DDO structure.
- Double-clicking an element in the Code Explorer will activate the Code Editor and position the cursor on the line of code where the element is declared. Double-clicking actually synchronizes all views for the current file to the selected element.
Changing Object Order
Code Explorer can be used to change the order of objects declared in a source file.
To move an object, select it in the Code Explorer, then press Alt + Up Arrow or Alt + Down Arrow to move the object up or down relative to its sibling objects. The object declaration and all of its nested content will be moved above or below the relevant sibling object.
Code Explorer only supports moving an object relative to sibling objects of the same parent object, or root objects relative to each other.
You may also use the Move Object Up or Move Object Down context menu items to move an object.
Managing Web Properties
Code Explorer supports managing the Web Property interface of your web application’s web objects.
Property declarations inside a cWebObject subclass declaration or object declaration can be defined as Web Properties. Web properties are represented in the treeview with the following icon:
You may change whether a property declaration is a Web Property or not by selecting it in the treeview and clicking the Web Property button on the toolbar or selecting the Web Property option in the context menu.
Managing Published Methods
Code Explorer supports managing the published interface of your Web Services Objects or Web Browser Objects.
Methods belonging to a Web Service Object (WSO) or Web Browser Object (WBO) that are published are represented in the treeview with the following icon:
You may change the published state of a WSO or WBO method by selecting it in the treeview, then choosing Publish from the context menu (this toggles the method's published state).
Toolbar

The Code Explorer's toolbar supports the following options:
Move Object Up
If an object declaration is selected, then this option will attempt to move the declaration above the previous sibling object declaration.
Move Object Down
If an object declaration is selected, then this option will attempt to move the declaration below the next sibling object declaration.
Web Property
If a property declaration belongs to a cWebObject subclass or web object declaration, then this option toggles whether the property is a Web Property or not.
Published
If a method declaration element belonging to a Web Service Object or a Web Browser Object is selected, then this option toggles the method's published state.