Using Tabs in the Cradle UI

The Cradle WorkBench UI is divided into panes. Each pane is a region that can contain one or more tabs. A tab is a container with a selectable name and a rectangular area that contains the results of running a query, report, metric or graph, or a single item that is being edited. Using tabs is a way to maximise your productivity with the Cradle UI by helping you to arrange queries, items and other information, either so you can see everything at the same time, or so the information is presented in a layout that you find convenient.

Layout of a Tab

A tab is a rectangular region in the Cradle UI that has a name, a close control and a rectangular region containing the result of a query, a report, a metric, a matrix, a pivot table, or a dashboard:

Using Tabs in 3SL Cradle WorkBench
Tabs in a Pane in the Cradle UI

Tabs exist inside panes.

Each pane can contain up to 16 tabs. You can have many panes open in the UI at the same time.

When you create a new tab, it will open in the currently-selected pane. So, if you run a query, that query will open in a new tab in the current pane. If you open an item, it will open in a tab in the current pane.

Tab Names

Each tab has a name, shown above it, that is name of the query, report, metric, graph or pivot table shown in the tab, or some details of the item shown in a form.

Using Tabs

Next to a tab‘s name is a button, you can click this button to close the tab.

You can also press CTRL-W to close a tab, or choose Close Tab from the context-sensitive menu that will appear if you right-click inside a tab.

You can move a tab between panes by:

  • Put your cursor in the name of the tab to be moved
  • Press the left mouse button
  • Drag into the new pane
  • Release the mouse button

Horizontal or vertical scrollbars will appear if a tab’s contents are larger than the screen area available. You can increase the area used to display a tab by either:

  • Use the sash control to increase the size of the pane that contains the tab
  • Maximise the pane containing the tab using its pane control menu, or simply double-clicking the pane’s legend

Using Panes in the Cradle UI

The Cradle WorkBench UI is divided into panes. Each pane is a region that can contain one or more tabs. A tab is a container with a selectable name and a rectangular area that contains the results of running a query, report, metric or graph, or a single item that is being edited. Using panes is a way to maximise your productivity with the Cradle UI by helping you to arrange queries, items and other information, either so you can see everything at the same time, or so the information is presented in a layout that you find convenient.

Layout of a Pane

A pane is a rectangular region in the Cradle UI that has a legend and a set of controls:

Using Panes in 3SL Cradle WorkBench
A Pane in the Cradle UI

The pane’s contents are one or more tabs. Each tab contains the results of a query, report, matrix, metric, graph or pivot table, or an item in a form.

Each pane can contain up to 16 tabs. You can have many panes open in the UI at the same time.

When you create a new tab, it will open in the currently-selected pane. So, if you run a query, that query will open in a new tab in the current pane. If you open an item, it will open in a tab in the current pane.

Pane Legend

The pane’s legend appears when you select a tab inside it. The legend will be the name of the tab that you have selected.

You can double-click the legend to maximise the pane. This will maximise the pane to fill the WorkBench UI, overlaying all other panes. When a pane is maximised, double-click the legend again to minimise the pane. This will restore the pane to its original size.

Pane Controls

Each pane has a set of controls. These controls are the most important part of using panes to control the Cradle UI:

Using Panes in 3SL Cradle WorkBench
Pane Controls and How to Access Them

You can use these controls to:

  • Maximise the current pane, an alternative to double-clicking its legend
  • Close the current tab, if any
  • Empty the pane by closing all of its tabs
  • Close the pane, and all tabs inside it
  • Close all panes

More usefully, you can also:

  • Split the pane horizontally into two panes
  • Split the pane vertically into two panes

Using Panes

You can split panes any number of times. This divides the UI into an arrangement so you can see several queries at the same time, or so you can see many items at the same time.

As an example:

Using Panes in 3SL Cradle WorkBench
Creating New Panes by Splitting

A large screen will be helpful!

There are sash controls between panes. Move your cursor between two panes and it will change to a pair of arrows. If you press, drag and release the left mouse button, you can adjust the relative sizes of adjacent panes. This will proportionately adjust the sizes of all tabs inside these panes. For example:

Using Panes in 3SL Cradle WorkBench
Adjust Pane Sizes with Sash Controls

Forms – Collapsible Panels

WorkBench Forms

A form is a layout template that is used to display information about items within Cradle. There are multiple attributes of an item that may be displayed, from the name, to categories, to frames.  Forms can soon get complicated, this is where collapsible panels can help.

Collapsible Panels

A feature new in Cradle 7.4

Collapsible panels are placed as a row, or a column on a form definition. These can be barked to display as a normal row/column when opened or to “Show collapsed by default”

The bar at the top of the panel toggles its open state.

Q&A

Some of the questions often asked regarding forms.

Q: What if a user does not have a skill required to see an attribute?

A: The form will not display this particular aspect of the item. There is no need to create a separate form.

Q: I’ve just added some new frames and categories. Do I have to design a new form?

A: No, the Automatic scope forms will generate a basic form with the new elements included.

Q: Do I have to start from scratch designing a form?

A: No, you can choose any existing form (including the automatically generated ones) suitable  for that item type, make your changes and then ‘Save As‘ to store the newly altered definition.

Q : Do you have to show everything that every user needs on a form?

A: No, forms can have a scope of System, Automatic, Project User type, Team User, or Personal. This allows different users to show different aspects of an item most relevant to them.

Q: Can I show related items?

A: Absolutely, linked items can be shown within a form.

Q: Can I convert existing forms?

A: Yes, just select an existing Row or Column and change the Syle from Basic to Panel. then Save or Save As

Increase the UI Object Limit

The UI of the WorkBench tool in 3SL’s Cradle is very flexible. It allows you to display the items and the results of running queries in individual tabs. You can split the display into panes and have many of these tabs in each pane. You may need to increase the UI Object limit if you want to have a very complex WorkBench UI.

UI Object Limit

Each part of the UI uses Windows resources called User interface objects. There is a limit on the number of these UI Objects that each WorkBench process can allocate.

The default is a maximum of 10,000 UI Objects per process. This can be increased to a maximum of 18,000 UI Objects per process by changing a setting in the Windows registry.

If you open so many tabs that WorkBench exhausts the UI Objects that it can allocate, then the WorkBench UI will hang.

Increase the UI Object Limit

To increase the UI Objects Limit you must edit the Windows registry value:

HKEY_LOCAL_MACHINE\SOFTWARE
    \Microsoft\Windows NT\CurrentVersion
    \Windows\USERProcessHandleQuota

The steps are:

Set the UI Object Limit
Set the UI Object Limit
  1. Press Windows+R and enter regedit and click OK
  2. Navigate to the above registry entry
  3. Double click the entry for USERProcessHandleQuota, and set Decimal
  4. Enter the new value 18000 and click OK:

    DWORD USERProcessHandleQuota edit dialog
    USERProcessHandleQuota
  5. Exit the registry editor

This change takes effect on any processes created from now on.

Do I Need to Do This?

In general, no you do not need to make this change.

We have only seen one case where this change was necessary. In this case, a customer had a form with 75 frames display in it. The WorkBench UI hung when a user tried to open the 6th item concurrently when using this form.

Increasing this limit allowed the user to open 10 items concurrently using this (very!) large form.

Of course, if you want to increase the UI Object limit as a precaution, then it will not do any harm!

Controlling Your Initial View

Query with a View

Each query can have an initial View associated with it. Each time this query is run, it will apply the view. This is the best way of controlling your initial view for a particular query.

Shown in the screen shot below the project viewresults‘ has been set in the queryMy Results‘ each time this query is run the columns specified in the View Details are shown. There’s nothing to stop a user selecting a different view in the ribbon later.

showing the query, view setup and results
Initial View Settings

Remember that View

WorkBench is designed to remember the last view you used for a particular item type.  It’s likely that next time you run a query for the same item type, you’ll want the same view. Even if you close all your tabs, within the same session you are controlling your initial view of each query by the last choice you selected.

Initial Influence

You can control the initial view selected for a query in a project by associating a view with an item type in the project’s schema. Open Project Setup and select the item type and an appropriate view. When starting Cradle, this will be the view selected for this item type, the first time it it is queried. Thereafter, WorkBench will switch to  “Remember that View”.

setting an initial view in the schema
Initial View – Schema

QAB Queries and Views

The Quick Access Bar at the bottom of WorkBench as some auto generated queries and auto generated views for speed. If one of these is selected then the the view that is ‘remembered’ will be the last one of the Automatic views.

Special characters in regexes and how to escape them

Regex – Regular Expression

Cradle provides support for regular expressions, regular expressions are a means to find variable text in places such as:

  • Queries
  • Find dialogs
  • Category recognition strings
  • Category value validations

For instance, regular expressions (regexes) can be used in queries to find all items in which any frame, or a specific frame, or any of a list of frames, contains text matching the regular expression that you are searching for. For example, if you wanted to find all items containing sequences of capital letters followed by numbers, then the regular expression would be:

[A-Z]+[0-9]+


Whilst you are here, take a look at Why is Requirements Management Essential for your Business?


Special Characters

Some characters have special meanings within regexes these characters are:

CharDescriptionMeaning
\BackslashUsed to escape a special character
^CaretBeginning of a string
$Dollar signEnd of a string
.Period or dotMatches any single character
|Vertical bar or pipe symbolMatches previous OR next character/group
?Question markMatch zero or one of the previous
*Asterisk or starMatch zero, one or more of the previous
+Plus signMatch one or more of the previous
( )Opening and closing parenthesisGroup characters
[ ]Opening and closing square bracketMatches a range of characters
{ }Opening and closing curly braceMatches a specified number of occurrences of the previous

Examples

Finished\? matches “Finished?
^http matches strings that begin with http
[^0-9] matches any character not 0-9
ing$ matches “exciting” but not “ingenious
gr.y matches “gray“, “grey
Red|Yellow matches “Red” or “Yellow
colou?r matches colour and color
Ah? matches “Al” or “Ah
Ah* matches “Ahhhhh” or “A
Ah+ matches “Ah” or “Ahhh” but not “A
[cbf]ar matches “car“, “bar“, or “far
[a-zA-Z] matches ascii letters a-z (uppercase and lower case)

Using Special Characters as Literal Characters

If you want to use any of these as literal characters you can escape special characters with \ to give them their literal character meaning.

Example

If you want to match 1+2=3, you need to use a backslash (\) to escape the + as this character has a special meaning (Match one or more of the previous).
To match the 1+2=3 as one string you would need to use the regex 1\+2=3

For further information on using regexes in Cradle see our online help.

 

What’s CRADLE_ERRORSTACK?

Environment Variable or Command-line Switch Stack-tracing

As with many complex products Cradle monitors its internal operation and on the rare occasion that something goes wrong it writes information to a log. CRADLE_ERRORSTACK controls how much information is logged internally and output on these occasions.

If in the unfortunate case a Cradle tool crashes, there will often be a log produced in the %CRADLEHOME%\logs\errors directory. This will enable 3SL Support to diagnose simple cases such as a lack of memory on the machine. If the case is more complex, the development team may need to know at which point the program was processing at the time the error occurred. CRADLE_ERRORSTACK will enable additional internal logging that will output a simple execution stack trace into the log. This can aid diagnosis and resolution.

Switching Stack Trace On and Off

CRADLE_ERRORSTACK is an environment variable. You can set it via the control panel’s Advanced system settings (see the screenshot).

In Linux if you are editing the environment config files bashrc, profile, etc for either the system /etc/profile or the user ~/.bashrc then use:

export CRADLE_ERRORSTACK=true

Or as we now set CRADLEHOME in /etc/profile.d/cradle.sh you can put the ‘CRADLE_ERRORSTACK=true’ variable in this file.

Or you could start the Cradle tool from within a command shell, (On Windows®) press windows key type cmd and then in the shell set CRADLE_ERRORSTACK=true, then launch the tool e.g. "%CRADLEHOME%\bin\exe\windows\work.exe". You can also set a -errorstack parameter to your command line option, i.e. work.exe -errorstack to start WorkBench with the stack on.

Turning on CRADLE_ERRORSTACK environment variable
Environment Variables

Should I leave CRADLE_ERRORSTACK on?

Generally there is no need to leave the stack trace on all the the time. There is a small performance hit if you do, so unless you are having problems we don’t advise you leave it enabled.

What if that still does not sort the issue?

3SL Support may ask you to turn on tracing which produces a complete execution trail from the product. This has a large overhead and uses disk space and is only in used in the very trickiest of issues. Rest assured, it’s unlikely you’ll have to use  it, but if you do there is a post here that explains tracing.

Article UpdateD

27/04/2021 – Using CRADLE_ERRORSTACK in Linux

Change Attributes for Many Items

You may need to change attributes or a category of many items and there is an easy way to do this in one go.

Changing Attributes

The attributes of the same or different item types can be changed at the same time. In the image below, all the Group attributes are empty and I want to group this set of items. To change attributes, select them all, right click and select Properties.

Item Properties UI for Many Item Types
Item Properties UI for Many Item Types

In here I can enter some text in the Group attribute and when I click OK all the items selected will be up dated. I could change any of the options shown in Item Properties and it would up date all the items with the same information.

All Items Updated
Many items of different item types are updated

This will work on items in link views as well so you can change all of the linked items at one.

Changing Categories

This will only work for items of the same item type. Select all the items you wish to change, right click on them and select Properties. If all items are the same type with the same categories, Item Properties will show all of the categories for that type.

Item Properties for many items of the same item type
Item Properties for many selected items of the same item type

Selecting a new option will change all the items at the same time. Multiple Category types can also be changed here and will affect every item selected. All of the categories can be changed at the same time, if required, along with all the attributes shown above.

Related Articles:

For further information on attributes and altering data:

Select Operations in Cradle

Since Cradle is not intelligent (unlike its users!), you have to tell it what you want to it operate on, before you tell Cradle to do anything. There are several select operations in Cradle, depending on what you are working with. Most of these select operations are common to other pieces of software, so what follows may not contain any surprises.

Select Operations in Cradle

In general, you will either select:

  • Items, to perform an operation on them
  • Text, to manipulate the text in some way

How to Select Items

When you see a collection of items, in a list, table, document or tree, you can select them and then apply an operation to them. So, starting with this table of items:

Select Operations in Cradle
A List of Items

the select operations in Cradle are:

  • Select all items by pressing CTRL-A:
Select Operations in Cradle
A List of Selected Items
  • Cancel all selections by pressing CTRL-D:
Select Operations in Cradle
A List of Items With None Selected
  • Select an individual item by positioning the cursor over it and then click your LEFT mouse button:
Select Operations in Cradle
A List of Items With One Selected
  • Select a range by positioning the cursor to the other end of the range and press SHIFT and the LEFT mouse button:
Select Operations in Cradle
A List of Items With a Range Selected
  • To add items to the set of selected items, or to remove a selected item from the set of selected items, position your cursor and press CTRL and the LEFT mouse button:
Select Operations in Cradle
A List of Items With Several Items Selected

You can combine these select operations in Cradle, as shown above.

If the results are not what you want, press CTRL-D and start again!

How to Select Text

The majority of items created in Cradle contain text, either plain text or rich text. You can store any amount of text (well, up to 1 TByte) inside each attribute (called a frame) in an item. You can have any number of attributes in each item.

So, items can store a little text, or an enormous amount of text.

When you edit text, you will see a cursor that is a vertical line. This shows you where text will be entered when you type on the keyboard, or paste text that you copied elsewhere.

The select operations in Cradle for text are:

  • Select all items by pressing CTRL-A
  • Cancel the selection by pressing CTRL-D
  • To select a position in the text, position your cursor and press the LEFT mouse button
  • Select a word by positioning your cursor anywhere inside the word and double-click, press the LEFT mouse button, quickly, twice,
  • Select a paragraph by positioning your cursor anywhere inside the paragraph and triple-click, press the LEFT mouse button, quickly, three times
  • You can select a range of text by positioning your cursor at the start, or end, of the range, and press the LEFT mouse button, drag the cursor, and release the mouse button
  • You can also select a range of text by positioning your cursor at the start or end of the range, then press SHIFT and then press Cursor Left, Right, Up or Down to extend the range in each direction.
  • If you ALSO hold the CTRL key, then Cursor Left and Right will extend the selection by one word
  • If you ALSO press the CTRL key, then Cursor Up and Down will extend the selection by one paragraph
  • You can change the end of a range of selected text to the start or end of a paragraph by pressing the SHIFT key and then pressing Home or End
  • You can change a range of selected in large amounts by pressing the SHIFT key and then pressing Page Up or Page Down

By combining these select operations in Cradle, you can easily work with even long blocks of text.

If you have not tried some of these technique, please try them!

Multiple Data Cells – Document View

Heading Styles in Document View

New Cradle 7.3.1 Feature (Multiple Data Cells – Document View)

We’ve updated Document View in Cradle to allow triggering by content of Multiple Data Cells.

Document View is a style that gives a quick output from a query in a style akin to a document with heading levels being shown in different styles. These are triggered when the hierarchical attribute is present in the first cell.

Multiple Data Cells allow the combination of data values within one View Cell. If your Multiple Data Cell includes the hierarchical element, its Document Style behaviour will now be the same as if it were the element itself.

In the screen-shot below the Key is shown in the top view and then as part of a Multiple Data Cell in the lower part.

 

Showing the dialogs and results to use multiple data cell in document view
Multiple Cell in Document Style

Output to Hard Copy

When there is no need to create a full formal document through Document Publisher, it is possible to publish the view to HTML or RTF quite easily. Simply ‘right click’ on the text in the view and select  Publish Table…. and then ensure that the option Use document-style fonts is selected.

Dialog and result of publishing table with document style fonts
Publish Table – Document Style Fonts

As can be seen in the screen-shot the multiple data cells – Document View Fonts  are preserved in the output. Now you can use whichever printer is attached to your system to produce the hard copy from the text in your browser or the RTF file, or save a tree and email the resultant file where appropriate.

Views

Cradle Views are a simple yet flexible way to arrange your tabular query output. To learn more see the help section on Views.

Related Articles

It is possible to copy the text from a multiple cell to your clipboard for use elsewhere.