Code Editor - Overview

Applies to TestComplete 15.31, last modified on March 17, 2022

About

The TestComplete Code Editor provides advanced features for writing and editing scripts in any of the supported scripting languages - VBScript, JavaScript, JScript, Python, DelphiScript, C++Script or C#Script. The Code Editor appears when you right-click a unit in the Project Explorer panel and choose Edit from the context menu.

You can work with each Editor window in the same manner that you work with other editors within the Workspace panel. For instance, you can dock editors within the Workspace panel as needed.

For more information on the Editor window, see About Code Editor.

Syntax Highlighting

For each of the supported languages, the Code Editor uses syntax color highlighting - different fonts and colors for different code elements, making them easier to locate and distinguish. You can change the settings in the Code Editor Options dialog. To call this dialog, do any of the following:

  • Click the Call the Panel Options Dialog button on the Code Editor’s toolbar.

  • Right-click anywhere in the Editor window and select Panel Options from the context menu.

The Editor Options dialog also lets you modify other settings of the Editor: the font name and size, the background style, tab positions, and so on.

Getting Help

To get online help for a term, move the cursor to this word and press F1. If a topic does not exist for the word, TestComplete displays the topic for the Code Editor panel.

About the Code Explorer

TestComplete includes another panel, Code Explorer, that you can use to navigate among script routines easily. In addition, you can use it to move routines from one unit to another quickly.

Note: By default, the Code Explorer panel is hidden from TestComplete. To make the panel visible, select View > Select Panel from the TestComplete main menu, and then select Code Explorer in the resulting Select Panel dialog.

Opening Multiple Editor Windows

You can open multiple Editors to view code of several script units to copy and paste code among them. You can also view the code of the same unit in several Editor windows. To do this, click somewhere within the Code Editor’s tab of the desired unit and select New Editor Window from the Workspace toolbar. A new instance of the Editor will appear. Also, you may right-click the caption of the Code Editor in which the desired unit is opened and select New Editor Window from the ensuing context menu.

See Also

Code Editor Options
Key Mapping
Debugging Tests
Unicode Support
Testing Android Applications (Legacy)

Highlight search results