[TOC] [Prev] [Next] [Bottom]



Chapter Two

Tango Editor Basics


An Explanation of the Tango Editor Interface and Some Common Operations

This chapter helps you orient yourself to the Tango Editor interface and some of the common operations available to you.

The topics covered in this chapter include:

  • Tango Editor window components
  • using context-sensitive menus
  • using HTML editing windows
  • using Word Wrap
  • using the SQL Query window
  • finding and replacing text or regular expressions
  • working with multi-column lists in action editing windows
  • keyboard shortcuts.
[top] [back to top]


Tango Editor Window Components

To start Tango Editor, do either of the following:
  • In the Tango folder, double click the Tango Editor icon.
  • From the Start menu, select Programs, point to Tango Enterprise 3.0, then to Tango Editor.

The main Tango Editor window appears.

The main title bar displays the Tango Editor name and the name of the current (front most) application file or the SQL Query window.

The menu bar contains pull-down menus for Tango Editor commands. Click a menu title to open it, then click a command to select it. Commands appearing in gray do not apply to the operations you are trying to perform.

The main window area displays one or more application file windows, action editing windows, attribute editing windows, or the SQL Query window.

The Status Bar displays messages about the Tango Editor environment, such as when connecting to a data source, the currently connected data source, or when passing the cursor over a toolbar icon to display its name/function. It also shows if Caps Lock, Num Lock, and Scroll Lock on the keyboard are switched on.

The Workspace includes tabs for Data Sources, Snippets, and Projects, if any exist. You switch among the three workspaces by clicking the corresponding tab.

Click icons on the Actions Bar and drag them into an open application file to add them to the file.

Click icons on the Attributes Bar to assign attributes to selected actions.

Click icons on the toolbar to select the main Tango Editor commands. For example, to save an application file, you can either choose Save from the File menu, or click the Save icon on the toolbar.

Viewing Interface Objects

You can choose to show or hide the Workspace window or any of the toolbars by enabling the object's name from the View menu. A checkmark beside the name indicates the object is visible in the interface. Uncheck the name to hide the object.

To hide the Workspace window, you can also right click it and click Hide from its context-sensitive menu.

Floating and Docking Interface Objects

The Workspace window and toolbars are, by default, docked to the Tango Editor interface. You can drag them from the interface to undock, or float, them anywhere on your desktop. You can also dock them again.

To float an object on your desktop, simply click the undocking bars and drag the object to the desktop. If you want, you can then resize the object. Position the cursor over the object's border, and when the cursor changes to the resize arrow, click and drag its border.

To dock the object to the interface again, drag it to anywhere in the toolbar area.

Floating and Docking the Workspace Window

You can float the Workspace window in the Tango Editor main window or anywhere on your desktop, or dock it to the interface. To do this, you enable (checkmarked) or disable (unchecked) commands appearing in the Workspace window's context sensitive menu.

To float the Workspace window only in the Tango Editor main window, right click the Workspace window and click Float in Main Window. A checkmark appears beside the command indicating the option is enabled. This prevents you from dragging the Workspace window beyond the borders of Tango Editor.

If you want to drag the Workspace window to anywhere on your desktop, disable Float in Main Window and drag the Workspace window to another position.

To dock the Workspace window to the interface, drag the Workspace window to the toolbar area.


!Note: You cannot dock the Workspace window to the interface with the Float in Main Window option enabled.


To avoid inadvertently docking the Workspace window to the interface, right click the Workspace window and disable Allow Docking.

[top] [back to top]


Using Context-Sensitive Menus

In most Tango Editor windows and dialog boxes, you can position the cursor on a particular area of the screen and click the right mouse button to display a context-sensitive menu of commands. The commands that appear relate to the object you clicked. Commands that appear grayed out are not applicable to the current object.

For example, another way to hide the Workspace window is to right-click it and select Hide from the context-sensitive menu.

[top] [back to top]


Properties Window

The Properties window allows you to view information about and add comments to a selected object. Selectable Tango objects include data sources (including tables and columns), application files, and actions. In general, the Properties window changes to show the properties of the currently selected object.

The following is an example of an Action Properties window for a Search action.

To open any Properties window
  1. Select the object you want to view information about.
  2. Do either of the following:
    • From the View menu, choose Properties.
    • Right click the object, and choose Properties from the context-sensitive menu that appears.

The Properties window can be left open. Clicking an object with properties updates the window to show information about that object's properties.

[top] [back to top]


HTML Editing Window

Each action in an application file can have HTML associated with it. Whenever you open the assigned attribute of an action, the corresponding HTML editing window appears. You can create or edit any assigned HTML using this window. An example of an HTML editing window is as follows.

The title of the window follows the form:

<Document> : <Action> : <HTML>

This example shows the HTML editing window for the Results HTML of a Search action named "RecordList" within the Sample.taf application file.

Tango Editor supports the standard editing commands. The Edit menu displays the following editing commands when an HTML editing window is open.

You can also right click the HTML editing window to display a context sensitive menu at the cursor position in the window. The following table lists the commands available in the menu.

Command

Function

Undo

Undoes the last change made to the text.

Cut

Removes the selected text from the window.

Copy

Copies the selected text to the clipboard.

Paste

Pastes text on the clipboard at the cursor position.

Delete

Deletes the selected text.

Select All

Selects all text within the HTML editing window.

Insert Meta Tag

Displays the Insert Meta Tag dialog box. For more information, see "Using Meta Tags".

Closing the editing window automatically saves any changes you make. To cancel any changes, you can choose Undo, or close the file without saving.

For more information, see "Setting Preferences".

To make editing of your files easier and clearer, you can color code many of the HTML and text components that may appear--HTML, meta tags, attributes, default text, and comments.

You can also position text using tab characters. Tabs are stored as tab characters and are not converted to spaces. Tabs have no effect on the display of HTML in the Web browser; they are used to make the HTML that you enter more readable.

You specify the number of space characters that equal one tab character in the Preferences dialog box. You can also specify whether you want Tango to insert tab characters to start a new line at the same indent level as the previous line.

For more information on converting former query documents to Tango application files, see the Getting Started Guide.


!Note: If you open an application file created in an earlier version of Tango, any <@COL> meta tags are automatically converted to <@COLUMN> meta tags.


You can enter any amount of text in an HTML editing window. You can also drag and drop text from elsewhere, for example, from other editing windows.


!Note: Word wrap is not available in the HTML editing window.


Selecting lines of text in an editing window is easy. You simply use the selection strip next to the line to select the entire line. When you select a line, it is highlighted. The following describes the operations you can perform using the selection strip.

  • To select a single line, click the selection strip beside the line you want to select. The entire line is highlighted.
  • To select multiple lines, depress the mouse button in the selection strip next to the first line you want to select and drag the cursor up or down the selection strip to highlight subsequent lines.

To indent selected lines, press the Tab key. All selected lines are indented the number of characters equal to one tab character. Press the Tab key again to indent the selected lines farther; press the Shift+Tab keys to reduce the indention.

You set the number of characters equal to a tab character in the Preferences dialog box. See "Text".


!Caution: You can only use the Tab key to indent the selected lines. Using the Space Bar instead replaces all the selected lines with a single space character.


  • To move the selected lines elsewhere in the editing window, simply drag them to a new position. When you drag the selected lines, the cursor changes to Release the mouse button where you want the selected lines to appear.
.


!Note: You can also use the standard editing commands (such as Undo, Cut, Copy, Paste, and Delete) on text selected using the selection strip.


The HTML editing window is common for any of the HTML attributes that may be assigned to an action--Results HTML, No Results HTML, and Error HTML. Only the applicable attribute tabs for the selected action appear at the bottom of the window.

You switch among the HTML editing windows by clicking the appropriate tab.

Only the applicable page or response HTML tabs appear at the bottom of the window.

You can also open the attribute HTML associated with an action by doing one of the following:

  • Select an action icon/name, and choose the attribute type from the Attributes menu.
  • Right click the action icon/name, and choose the attribute type from the context sensitive menu.
  • Double click the attribute icon in the application file.

The corresponding HTML editing window opens.

For more information on customizing page and response HTML for the Search Builder, see "Configuring the Search Builder" .

The Search Builder also uses HTML editing windows so you can customize page HTML (Header and Footer) and response HTML (Update Response, Delete Response, and No Results) for the Search, Record List, and Record Detail pages. For example, the following HTML editing window shows the Header HTML for the Search Builder's Record Detail page in the Sample.taf application file.

In addition to editing an action's or Search Builder's associated HTML, you can also use Tango's editing capabilities to create and edit HTML and text files. The editing capabilities and window settings described for HTML action attributes apply equally to HTML and text files opened for editing with Tango Editor.

To create a new HTML or text file

From the File menu, choose New, then HTML or Text File from the submenu.

A blank editing window opens.

The default window name is "Untitled1", until you save it as another name. Subsequent new windows are named "Untitledn", where n is the next number in the series, that is, the second window opened is "Untitled2", and so on.

To save a new HTML or text file
  1. From the File menu, choose Save or Save As.

    The Save As dialog box appears.

  2. In the File name field, type the name of your file and an appropriate extension. The default extension is *.txt.

    The Save as type drop down list includes file types: *.html, *.htm, *.htx, *.txt, *.css, *.inc, *.log, *.xml, *.XSL, *.dtd, *.sql.

    When you save a text file and a project is open, Tango automatically asks if you want to add the saved file to the open project.

To open an HTML or text file
  1. From the File menu, choose Open.

    The Open dialog box appears. The Open dialog box displays the same Files of type as listed in this table.

  2. Select the file to open.
  3. Click Open.

!Tip: You can also open a file of a supported type simply by dragging it from the Windows Explorer into Tango Editor or onto the Tango Editor icon, if Tango Editor is not already open.


You can also split the editing window into two or more panes. This allows you to see text from different locations in the same HTML or text file at the same time.

This example shows text in adjacent panes from two different places in the same Readme.txt file. This is useful if you want to see text from different places in the same file at the same time, or if you want to cut, copy, or paste text between the open panes.


!Note: Split information is not saved with a file.


To split the editing window into multiple panes
  1. Move the cursor over a split box.

    A split box is located in the bottom left corner of the editing window and another in the upper right corner.

    The cursor changes to a resizing icon.

  2. Drag the resizing icons to create separate window panes.

[top] [back to top]


Word Wrap

The Word Wrap command in the View menu is available for certain text windows.

When the command is available, selecting it enables or disables word wrap. A checkmark indicates word wrap is enabled.

If word wrap is disabled, a horizontal scroll bar is available to view text outside the boundaries of the text window.

Word wrap is available in the Direct DBMS action window, Script action window, and File action window, among others.


!Note: Word wrap is not available in HTML editing windows.


[top] [back to top]


The SQL Query Window

For more information, see "Performing a SQL Query".

The SQL Query window gives you a convenient way of performing simple SQL queries within Tango Editor, for example, to test your Direct DBMS actions or to check database values.







If you want to resize the query and results areas, place the cursor over the areas separator to display the resizing icon.

Then click and drag it up or down to change the sizes of each area.

Setting Up a SQL Query

The components and functions of the SQL Query window are as follows:

  • Data Source Button. The data source you want to perform window operations against. When you first open the SQL Query window, the data source is set to None.

    If you change the data source assigned to the window, any existing connection closes.

  • Max. Matches. The maximum number of records you want the SQL query to return. You can select from 1, 10, 25, 50, or 100. The default is 10.

For more information on SQL COMMIT and ROLLBACK operations, consult your SQL documentation.

  • Commit and Rollback Buttons. Performs a SQL COMMIT or ROLLBACK operation on the assigned data source. COMMIT causes any changes made to the data source by the query to be saved. ROLLBACK causes any changes made by the query to be discarded.

    If you are not connected to a data source, these buttons are disabled.

  • Connect and Disconnect Buttons. Connects to or disconnects from the current data source.

    When you try to connect without first assigning a data source, the Data Source Selection dialog box appears to select a data source from.

  • Execute Button. Executes the SQL query in the query text area. If you are not connected to the data source when Execute is selected, the connection is made automatically.

    Any data returned by the SQL query appears in the Results area of the SQL Query window. If the Results area contains data and the current query returns no data, the Results area is cleared of any data.

    After execution, the connection to the data source remains open.

    To cancel an executed query, press the Esc key. If results are being returned when a cancel request is made, the Results area shows all the data returned to that point.

You can specify a different default font for text appearing in the SQL query text and results areas in the Preferences dialog box; see "Setting Preferences".

For more information, see "Dragging Actions into SQL Query Text".

  • Query Text Area. Displays the SQL query text to be executed.

    The query text area supports standard cut, copy, and paste operations, including drag and drop. You can drag and drop tables and columns into the SQL Query text area from the Data Sources workspace.

    You can also drag any database action (except Transaction) from an application file to the SQL Query window to see the SQL Tango generates for it.

    If you select only part of the SQL when executing the query, only that part is sent to query the database.

  • Results Tab. Displays in columns and rows the results of the SQL query.
  • Logs Tab. Displays the log of executed queries.
  • Status Area. Shows the current status of the SQL query. The status messages appear as follows:

    Status

    Description

    Not connected

    No connection is established.

    Connecting...

    Appears during connection to the data source.

    Connected

    Connection is established.

    Executing...

    Appears during execution of query.

    Rolling back changes...

    Appears during rollback operation.

    Committing changes...

    Appears during commit operation.

Dragging Actions into SQL Query Text

You can drag any database action, except a Transaction action, which does not generate SQL, from an application file into the SQL Query window.

When you do this, some SQL Query window attributes are set based on the contents of the action. The following attributes are automatically set:

  • Max. Matches (for a search action) is set to the action's maximum matches value; otherwise, it is set to unlimited.
  • The data source is set to the action's data source, and closes any existing database connection (if the data source is different from the current data source).
  • The SQL text is the data source-specific SQL that Tango Server generates when the action is executed.

    !Note: Any meta tags from the action are placed in the text as-is. It also does not include any text automatically added to the action's SQL by the server.


  • The Results area is cleared of the currently displayed results.

Performing a SQL Query

To perform a SQL query

You can also choose the SQL Query command from a context-sensitive menu. Right click the application file window or an open action window.

  1. From the Window menu, choose SQL Query.

    An empty SQL Query window appears.

  2. Click the Data Source button.

    When you first open the SQL Query window, the data source is None.

    The Data Source Selection dialog box appears.

  3. Select the data source you want to perform SQL Query window operations against and click OK to load the tables and columns of that database.
  4. From the Max. Matches drop-down list, select the maximum number of records to return from a SQL query: 1, 10, 25, 50, or 100.
  5. Click the Connect button to connect to the current data source.

  6. In the SQL Query text area, enter the SQL query text to be executed.
  7. Click the Execute button.

    If you select part of the SQL in the SQL Query text area, only that part is executed when you click the button.

  8. If you want to perform a COMMIT or ROLLBACK operation on the assigned data source, click the corresponding Commit or Rollback button.

The results of the SQL query, if any, appear in the Results area.

[top] [back to top]


Using Tango Application Files

A Tango application file provides a powerful and flexible means for you to construct dynamic applications that run on your Web server and that interact with databases, other applications, and users running Web browsers. They are like programs or scripts in that they determine what operations Tango Server performs. Tango Server provides the brains, but it does nothing without the specific instructions you provide in the form of application files.

You add actions to an application file. When Tango Server runs the application file, it generates the HTML that is used by the browser to display the forms required to allow interaction with databases and other applications.

You can use the Search Builder and New Record Builder to have Tango Editor build search and insert record applications for you.

An application file is a file containing a series of Tango actions that when executed by Tango Server generates HTML and controls interaction with databases and other applications.

Application File Window

In Tango Editor, whenever you open an application file, the application file window shows you the following information:

  • action icons and names, including those for builders, in the order Tango Server executes them (unless a control action redirects the flow of the execution)
  • attributes assigned to an action, if any
  • data sources for all database actions
  • any associated comments.

The application file window also includes icons for attributes and data sources.

Creating an Application File

To create a new application file

From the File menu, choose New, or in the toolbar click the New icon.

An untitled application file opens.

Dragging Columns

When creating or modifying a Tango application file and actions, you must specify which database columns to use in various places. To do this, you drag the columns from the Data Sources workspace to the appropriate place in the file.

To ...

Do This ...

Select contiguous columns

Click the first column you want to select and Shift click the last one.

Select discontiguous columns

Control click each of the desired columns.

Select all columns in a table

Drag the table name to the file.

To see the Data Sources workspace, click the Data Sources tab. A workspace appears containing information about data sources, such as the currently defined data sources and all tables and columns. If no data sources are set up yet, only the data source types appear.

Saving an Application File

See "Executing Application Files"

To save an application file
  1. From the File menu, choose Save.

    If the application file has never been saved, the Save As dialog box appears.

    If it has been saved previously, Tango Editor saves it using the existing name and location.

  2. Navigate to the desired location for the application file.

    For Tango Server to execute the application file it must be located in or below the Web server's document root directory.

  3. Name the application file.

    Tango application file names generally end in .taf. This is the standard suffix used to identify files that Tango Server should execute. With the plug-in, this extension is required, unless you change the mapping of extensions in your Web server. Consult your Web server documentation for details. With the CGI version of Tango Server and a suffix-mapping you set up yourself, you may use any extension you like. The .taf extension is added if no extension is specified.

  4. Choose Save.

    Whenever you change an application file, and the file has not been saved, an asterisk appears beside the file name. This asterisk is called a dirty (unsaved changes) indicator.

    Once you save the application file, this indicator disappears.

Saving an Application File as Run-Only

Run-only application files can be executed by Tango Server, but they cannot be opened by Tango Editor.

Saving an application file as run-only allows you to create and distribute packaged Tango solutions while preventing users from editing the actual application file. Run-only application files are executed and referenced by Tango Server in the same way as editable application files. Saving an application file as run-only does not make its execution any faster.


!Caution: You cannot edit a run-only copy of an application file, and there is no way to make a run-only file editable. Make sure you keep an editable copy of any run-only application file.


To make an application file run-only
  1. With an application file open in Tango Editor, choose Save As Run-Only from the File menu.

    The Save As dialog box appears.

    You are saving a copy of your application file as run-only. Your original application file is not changed.

  2. Name the run-only application file.

    !Tip: You may want to give the run-only versions of your application files a special name to identify their type, such as CustomersRO.taf, where "RO" represents run-only.


  3. Click Save.

    A run-only version of the application file is saved in the location you specified.


!Note: If you are distributing your Tango solution, your customers need to purchase Tango Server. Alternatively, you can license Tango Server for distribution with your solution. Contact Sales at Pervasive for more information.


Debugging Application Files

Setting the debug mode in Tango Editor lets you see useful information about your application file execution in your Web browser application.

To set the debug mode
  1. Open the application file you want debug information on.
  2. Do one of the following:
    • From the Attributes menu, select Debug Application File.

      A checkmark beside the command indicates the debug mode is enabled.

    • Right click the application file window, and select Debug Application File from the context sensitive menu.
    • From the View menu, choose Properties. Then select Debug Mode in the Application File Properties dialog box that appears.

When you execute the application file, debugging information appears at the bottom of the results returned. The debugging information shows information such as:

  • arguments passed in (search and post arguments)
  • actions executed
  • values of variables
  • SQL generated by database actions
  • warnings (such as references to missing arguments).

For more information, see "Configuring Tango Server".

You can force debugging for all application files by changing the debugMode system configuration variable using the application file that allows you to set system configuration (config.taf).

Executing Application Files

Application files are executed in the same way HTML files are viewed--simply by specifying the name of the file in a URL. For example:

http://www.yourserver.com/shop/additem.taf

This example executes an application file called additem.taf located in the shop folder on the server www.yourserver.com.


!Note: This example assumes you are running one of the Tango Web server plug-ins or extensions (available for Microsoft's Internet Information Server and Netscape's Web servers). If you are using the Tango CGI instead, the syntax required may be different. See the Getting Started Guide for details.


You can pass parameters to the application file by using search arguments. These are name-value pairs appearing after a question mark in the URL. For example:

http://www.yourserver.com/shop/additem.taf?item_num=8580

In this example, the item_num search argument has a value of "8580".

See "Assigning Variables With the Assign Action"

There are other ways of passing values to Tango application files. Form fields (post arguments) and cookies are two examples.

[top] [back to top]


Finding and Replacing Text

For more information, see "Using Regular Expressions".

In Tango Editor, you can perform operations to find, or to find and replace text in application files. Tango Editor can perform both normal searches and searches using regular expressions.

Performing Find Operations

For the purpose of this discussion, the term string refers to both character strings (that is, text) and regular expressions. You specify that the search is to treat the string in the Find field as a regular expression by selecting the Regular expression option in the Find or Replace dialog box.

If you want to find a certain string, you specify that string in the Find dialog box. If you want to find a certain string and replace it with another string, you do that in the Replace dialog box.

You can find any string that can be entered in any non-modal Tango Editor window. This includes values in criteria lists, action parameters you have entered--such as for the Limit to field in a Search action's Results window, custom SQL, If action conditions, External action parameters, custom column definitions, and HTML. Tango Editor cannot find a string you did not explicitly enter, for example, data source names, user names or passwords entered by users, column names in Select lists, and join information.

You can perform find, and find and replace operations in open application files, action editing windows, HTML editing windows and projects. Unless specified otherwise, Tango Editor begins searching at the insertion point indicated by the cursor and continues to the end of the search range specified in the Find in section of the dialog box.

To find, or find and replace a string
  1. Depending on the operation you want to perform, choose either Find or Replace from the Edit menu.

    The corresponding Find or Replace dialog box appears.

  2. Specify your find or find and replace options as follows:
    • Find. Enter the string you want to find.
    • Replace with. Enter the string you want to replace the string in the Find field with.
    • Match case. If you want to perform a case-sensitive search, select the Match case option; otherwise, Tango Editor searches for a match irrespective of letter case. For example, a search for "customer" would find all instances of "customer", "Customer", and "CUSTOMER".
    • Regular expression. If you want to search for the string as a regular expression, you must select the Regular expression option. Otherwise, a normal search is performed.
    • Find in. You specify the search range in this area of the dialog box.

      Current window. Select this option to perform the find or replace operation in the window active at the time you chose the Find or Replace command. If you have a string selected in the active window, it automatically appears in the Find field.

      File filename. Select this option to perform the find or replace operation in the file specified by filename. The name of the currently active file automatically appears as filename.

      All files in project. If you have a project open, this option is enabled. Select this option to perform the find or replace operation in all the files of the active project. If you have another application file open at the same time, which is not part of the project, Tango Editor excludes it from the find or replace operation.

    • Start at top. Select this option to start the find or find/replace operation at the top of the search range specified in the Find in section. If this option is not selected, Tango Editor performs the search starting from the current cursor position.

      !Note: If a search range is specified and the current cursor position is not within that range, the current cursor position is ignored and the search starts at the top of the specified range.


    • Find Next. Select this button to start the search for the string specified in the Find field from the specified starting position.
    • Replace. Select this button to replace the string specified in the Find field with the string specified in the Replace with field. Following the replace operation, Tango Editor automatically searches for the next instance of the find string.

      You can undo the last replace performed by selecting Undo from the Edit menu.

    • Replace All. Select this button to replace automatically all instances of the string specified in the Find field with the string specified in the Replace with field. There is no confirmation of any replacement; however, at the end of the operation Tango Editor displays a message telling you the number of replacements made.

      !Note: You cannot undo the Replace All operation. You can, however, choose to close a file without saving the changes to return it to its former state.


      If the search range involves several objects, those objects in which replacements are made are opened so you can save or discard the changes.

    • Cancel. Select this button to stop the find or find/replace operation and to close the dialog box.

Using Regular Expressions

A regular expression is formed by one or more special characters that represent a string of text.


!Note: To find a special character, precede it with a backslash, for example, \* finds the asterisk (*) character.


To find any single character

A period (.) finds any character except a newline character.

Expression ...

Finds ...

.use

fuse but not house

To repeat expressions

Repeat expressions with an asterisk (*) or a plus sign (+).

A regular expression followed by an asterisk finds zero or more occurrences of the regular expression. If there is any choice, Tango Editor chooses the longest, left-most matching string in a line.

A regular expression followed by a plus sign finds one or more occurrences of the one-character regular expression. If there is any choice, Tango Editor chooses the longest left-most matching string in a line.

Expression ...

Finds ...

a+b

ab and aab but not a or b

a*b

b, ab, and aab but not baa

.*use

use, mouse, and paint the house, but not chair

To group expressions

If an expression is enclosed in parentheses, ( ), Tango Editor treats it as one expression and applies an asterisk or plus sign to the whole expression.

Expression ...

Finds ...

(ab)*c

abc but not aabbcc

(.a)+b

xab but not b

To choose any character from many

A string of characters enclosed in square brackets, [ ], finds any one character in that string. If the first character in the brackets is a caret (^), it finds any character except those in the string

Expression ...

Finds ...

[abc]

a, b, or c, but not x, y, or z

[^abc]

x, y, or z, but not a, b, or c

.

A minus sign (-) within square brackets indicates a range of consecutive ASCII characters. For example, [0-9] is the same as [0123456789]. The minus sign loses its special meaning if it is the first character (after an initial caret, if any) or last character in the string.

If a right square bracket is immediately after a left square bracket, it does not terminate the string; however, it is considered to be one of the characters to match. If any special character--such as the backslash (\), asterisk (*), or plus sign (+)--is immediately after the left square bracket, it does not have its special meaning and is considered to be one of the characters to match.

Expression ...

Finds ...

[aeiou][0-9]

a9 but not ae

[^bm]ate

date but not bate or mate

END[.]

END. but not END;

To find the beginning or end of a Line

You can specify that a regular expression find only the beginning or end of the line.

If a caret (^) is at the beginning of the entire regular expression, it finds the beginning of the line.

If a dollar sign ($) is at the end of the entire expression, it finds the end of the line.

If an entire expression is enclosed by a caret and dollar sign (for example, ^the end$), it finds an entire line.

Expression ...

Finds ...

^(the house).+

the house guest but not paint the house

.+(the house)$

paint the house but not the house guest

To re-use a regular expression in the Replace field

Tango extends the regular expression functionality and allows you to remember and recall a part of a regular expression. Enclose the part to remember with parentheses. To recall it, use \n, where n is a digit that specifies which expression in parentheses to recall. Determine n by counting occurrences of ( from the left. You can only use this feature in the Replace field of the dialog box.


!Tip: For more information on constructing POSIX regular expressions, ask your local UNIX guru, consult the FreeBSD regex man page, or try doing an Internet search for the term "POSIX 1003.2".


[top] [back to top]


Working With Multi-column Column Lists

Many Tango actions include multi-column lists for entering parameters--the criteria list in the Search action, for example. This section describes basic techniques for working with these lists.

To select an entire row

Click the row's Column cell.

To move a row

Select the row and drag it to the desired location.

A flashing grey line indicates where the row is inserted when the mouse button is released.

Drop-down Menus

Various columns have drop-down menus in each cell. Place the cursor in the cell and click the mouse. A downward direction arrow appears. Click the arrow and the drop-down menu appears.

From a cell's drop-down menu, you can select from preset values (like "and/or" and "true/false").

To resize a column

Click at the edge of the column in the list's header, and drag.

To resize a column to fit the data in it, double click its right edge in the header.

To delete a row
  1. Select the row to delete.
  2. From the Edit menu, choose Delete, or press the Delete key on the keyboard.
[top] [back to top]


Keyboard Shortcuts

The keyboard shortcuts, as they appear in Tango Editor menus, are as follows:

Menu

Command

Shortcut

File

New

Open

Save

Ctrl+N

Ctrl+O

Ctrl+S

Edit

Undo

Cut

Copy

Paste

Insert

Delete

Select All

Find

Replace

Rename

Group

Ungroup

Insert Meta Tag

Ctrl+Z

Ctrl+X

Ctrl+C

Ctrl+V

Ins

Del

Ctrl+A

Ctrl+F

Ctrl+H

Ctrl+Enter

Ctrl+G

Shift+Ctrl+G

Ctrl+M

View

Properties

Alt+Enter

Attributes

Results HTML

No Results HTML

Error HTML

Ctrl+R

Ctrl+U

Ctrl+E

DataSource

Reload

F5

Window

SQL Query

Ctrl+Q

Help

Help Home Page

F1

When working in the Project, Data Sources, and Snippets Workspaces, or in the application file window, you can expand and collapse any parent object by one level using the left and right keyboard cursor keys. A parent object is any object denoted in the view by the plus sign (, expandable) and negative sign (, collapsible).

  • To expand the selected parent one level, press (right cursor key).
  • To collapse the selected parent one level, press (left cursor key).

You can also use keyboard shortcut keys in an open application file window to expand and collapse the parent object through all levels at one time.

  • To expand the selected parent, press Ctrl+
  • To collapse the selected parent, press Ctrl+


[TOC] [Prev] [Next] [Bottom]



docs@pervasive.com

Copyright © 1998, Pervasive Software Inc. All rights reserved.