Data Key Usage
Data Keys as Paths
Data Keys are relative, and use 'dot notation' to reference children. Meaning, if we have a nested data structure, we can use Data Key paths (also known as Keychains) to reference the nested data. In the key browser image below, we have a nested data source called Downtime. Downtime contains a number of columns, and then contains a reference to additional data called runInfo
. If we wanted to access the highlighted operator
data, we could use the keychain dot notation in the Designer - @Downtime.runInfo.operator@. Nested data sources are outside the scope of this page, but you can learn about Data source nesting in the Nested Queries section.
Array Index of Data
You can reference an individual object in a list using standard array indexing syntax (brackets) like this: @dataSource[0].columnName@
, where "dataSource" is a data source that contains a child data key named columnName.
Assuming a data source with the values listed below, we can retrieve the value of "Second Row" by specifying index 1
and the column stringValue
: @static_data[1].stringValue@
indexColumn, stringValue
0, "First Row"
1, "Second Row"
2, "Third Row"
4, "Fourth Row"
Colors in Expressions
Colors may be references in Keychain Expressions in several ways.
Colors in Hexadecimal
First, hexadecimal case-insensitive color codes may be used. The code must be wrapped in quotation marks to be evaluated correctly. Note that the color change will only appear when the report is executed. The easiest way to test the expression is to switch to the Preview Panel.
Below we see a Blue hexadecimal code of "0000FF" is used on the Fill Color of a Rectangle. The Fill Color on the Rectangle was originally set to White. Because the expression will not evaluate in the Design Panel, the Rectangle will appear as a White color.
However, switching over to the Design Panel will generate the report, and evaluate the expression. This in turn returns a Blue Fill Color.
The 7th and 8th digits may be added to specify an alpha channel, or the opacity of the color: 00 is fully transparent, while FF is fully opaque. Below, we see a similar rectangle overlapping an ellipse, but with a code of "0000FF40" . This represents ~25% opacity, so objects behind the rectangle will be visible, and the fill color will only be slightly opaque.

Parameters as Colors
You may also leverage Report Parameters to specify colors. This typically involves creating a parameter with a string datatype, and using the color expression function. Once created, you can simply create a dynamic data key reference on the property by dragging the parameter from the Key Browser onto the property in the Property Inspector. This way, you can have several components use the same color, and modify the color in a single location.
Strings as Colors
Additionally, case-insensitive string color names may be used to return a color. Again, the value must be wrapped in quotation marks.

The following string values may be used:
Value | Example | Value | Example | Value | Example | Value | Example | Value | Example |
---|
"beige" | |
"gold" | |
"lavender" | |
"pink" | |
"tan" | |
"black" | |
"goldenRod" | |
"lightGray" | |
"plum" | |
"teal" | |
"blue" | |
"gray" | |
"lime" | |
"powderBlue" | |
"violet" | |
"brown" | |
"green" | |
"magenta" | |
"purple" | |
"white" | |
"crimson" | |
"hotPink" | |
"maroon" | |
"salmon" | |
"yellow" | |
"cyan" | |
"indigo" | |
"navy" | |
"silver" | |
"clear" | Zero opacity. Similar to disabling the Fill property. |
"darkGray" | |
"ivory" | |
"olive" | |
"skyBlue" | |
|
|
"fuchsia" | |
"khaki" | |
"orange" | |
"red" | |
|
|