Chart

  • This component is not suitable for users that require assistive technologies. This component is not suitable for users who require assistive technologies.

A component that draws charts as an image, for example to send as a mail attachment.

This component is deprecated. You should not build new menu items using it.

File modes: Download | Save | Save and download | Batch

File mode: Save and download

The file is saved in the database and the user downloads a copy.

SQL

SQL Call: Get chart (mandatory)

Gets information about a chart that should be drawn.

The chart supports all numeric and date/time data types for its value-columns, not just decimal data.

May modify database: No

Parameters

@xxx string
In batch mode each column from the get batch call is passed as a parameter with the same name.

Resultset: Chart info

Information about the chart to draw. The value in the ChartType column determines which other columns and result sets are used.

If width and height are omitted a suitable size is picked for the chart.
Table count: repeated exactly once
Row count: exactly one row
Columns
ChartType mandatory string
Type of chart to draw.
Possible value Description
Column Column chart. Also known as vertical bar.
ColumnStacked A column chart (vertical bar) with all bars stacked.
HorizontalBar Horizontal bar chart.
HorizontalBarStacked A horizontal bar chart with all bars stacked.
Line Line chart.
Pie Pie chart.
Width optional int
Width in pixels.
Height optional int
Height in pixels.
ShowLegend optional bit
If the chart should show a legend describing its series. Default is 1.
CollectedLabel optional string
The label used for the "Other" slice. Mandatory if CollectedThreshold or CollectedThresholdPercent is specified.
CollectedThreshold optional decimal
Sets a threshold for where small values should be grouped together into a "Other" slice. Only used by pie charts.
CollectedThresholdPercent optional decimal
Sets a threshold, as a value between 1 and 99, for where small values should be grouped together into a "Other" slice. Only used by pie charts.
UseFake3d optional bit
If the chart should be drawn with a 3d-ish effect. Not used by line charts.
XLogBase optional decimal
Makes the x-axis logarithmic with the given base. Not used by pie.
XTitle optional string
The title on the x-axis. Not used by pie.
YLogBase optional decimal
Makes the y-axis logarithmic with the given base. Not used by pie.
YTitle optional string
The title on the y-axis. Not used by pie.

Resultset: Custom palette (optional)

Declares a custom palette to use for the chart's data.

The colors in the table will be used in the order they are declared.
Table count: repeated zero or one time
Row count: one or more rows
Columns
PaletteColor mandatory string

See Colors.

Resultset: X-axis (not used by pie) (optional)

Describes custom labels for the x-axis.

The XValue column must have the same data type as the XValue column of the chart data.

If a custom axis is specified then the chart's values must fit inside the range described by the axis.
Table count: repeated zero or one time
Row count: one or more rows
Columns
XValue mandatory decimal
Position of label.
XLabel optional string
Label.

Resultset: Y-axis (not used by pie) (optional)

Describes custom labels for the y-axis.

The YValue column must have the same data type as the YValue column of the chart data.

If a custom axis is specified then the chart's values must fit inside the range described by the axis.
Table count: repeated zero or one time
Row count: one or more rows
Columns
YValue mandatory decimal
Position of label.
YLabel optional string
Label.

Resultset: Series (not used by pie) (optional)

Declares and customizes the series in the chart.

If this table is omitted then series are derived from the SeriesName column in the chart values. If this table is present then it must declare all series used by the chart values.

If this table is omitted and the SeriesName column is omitted from the chart values then all values are treated as belonging to the same default series and no legend is shown.

Series are drawn and are listed in the legend in the order they occur in this table.
Table count: repeated zero or one time
Row count: one or more rows
Columns
SeriesName mandatory string
Name of the series. Must be unique.
Color mandatory string

Custom color for this series. See Colors.

LineType optional string
Line chart only. Type of line drawn.

Possible value Description
Line A normal line chart. Default.
Point Disconnected data points.
Range A line that uses two y-values and colors the area between them.
StepLine A step line.
MarkerType optional string
Line chart only. How data points are drawn.
Possible value Description
None Data points are not marked, only lines are drawn. Default.
Round The data points are indicated by circles.
Square The data points are indicated by squares.
ShowInLegend optional bit
If the series should be shown in the legend.
ShowValuesAsLabel optional bit
Whether the datapoints in the series should have its values diplayed as a label.
Default: Default behavior is to not include values as labels.
ValueLabelBackgroundColor optional string

The background of the datapoints labels. Only applicable if ShowValuesAsLabel is true. See Colors.

Default: Default is a transparent background.

Resultset: Pie values (pie)

Pie chart values.
Table count: repeated exactly once
Row count: zero or more rows
Columns
Value mandatory decimal
Value.
Label mandatory string
Label.
Color optional string

A color for the pie slice. Overrides the palette. See Colors.

Resultset: Bar values (columns and horizontal bar)

Columns and vertical bar chart values.
Table count: repeated exactly once
Row count: zero or more rows
Columns
XValue mandatory decimal
Value on the x-axis.
YValue mandatory decimal
Value on the y-axis.
SeriesName optional string
Name of the series the value belongs to. See the documentation for the Series table for more information.

Resultset: Line values (line)

Line chart values.
Table count:
Row count:
Columns
XValue mandatory decimal
Value on the x-axis.
YValue mandatory decimal
Value on the y-axis.
Y2Value optional decimal
The second value on the y-axis. Mandatory for range series, not used by other series.
SeriesName optional string
Name of the series the value belongs to. See the documentation for the Series table for more information.

SQL Call: Save chart (mandatory)

Saves a generated chart.

May modify database: Yes

Parameters

@Document binary
The chart.
@DocumentContentType string
The chart's content type.

Resultset: Forwarding (optional)

Table count: repeated zero or more times
Row count: exactly one row
Columns
ADMIN_ErrorMessage optional string

Displays a user friendly error message to the user. This blocks any forwarding for the user.

ADMIN_ConfirmDelete optional string

Displays a user friendly confirmation message to the user with a delete button as the confirm button. If the user chooses OK the SQL call will be rerun with the parameter @ButtonAction set to 'Delete'.

ADMIN_ConfirmQuestion optional string

Displays a user friendly confirmation message to the user with a question style. If the user chooses OK the SQL call will be rerun with the parameter @ButtonAction set to 'Confirm'.

ADMIN_ConfirmWarning optional string

Displays a user friendly confirmation message to the user with a warning style. If the user chooses OK the SQL call will be rerun with the parameter @ButtonAction set to 'Confirm'.

ADMIN_InfoMessage optional string

Displays a user friendly info message to the user. When the user clicks OK the user is forwarded.

ADMIN_SuccessMessage optional string

Displays a user friendly success message to the user. When the user clicks OK the user is forwarded.

ADMIN_Dialog optional string

The dialog alias of a predefined dialog to show the user. Must be the first column in the result set table. Use multiple result set tables to combine with other forwarding.

Use the menu item "Admin > Dialogs" to register new dialogs or find aliases for existing ones.

<xxx> (for ADMIN_Dialog) optional any

Any column without special meaning in the result set with the first column ADMIN_Dialog will be used to make replacements of placeholders in the message and title text.

ADMIN_DebugInfo optional string

Additional information to show the developer when using ADMIN_Dialog.

<passing_field> optional string
Any column with no other specific meaning will pe passed along to the menu item you are forwarding to.
ADMIN_CancelCidStepsBack optional int
Number of steps in the page history to jump back if the user clicks Cancel in an ADMIN_FORCE dialog (the default being none). This value overrides cancelcidstepsback specified in the query string.
ADMIN_CancelReturnToMenuItem optional string
Jumps back to the menu item with this alias if the user clicks Cancel in an ADMIN_FORCE dialog (the default being none). If no prior menu item is found with the given alias, then an error is thrown.
ADMIN_CancelMenuItem optional string
Alias of the menu item to execute if the user clicks Cancel in an ADMIN_FORCE dialog (the default being none). This value overrides cancelmenuitemid specified in the query string.
ADMIN_CancelMenuItemId optional int

Deprecated. Use ADMIN_CancelMenuItem instead.

Id of the menuitem to execute if the user clicks Cancel in an ADMIN_FORCE dialog (the default being none). This value overrides cancelmenuitemid specified in the query string.

ADMIN_CidStepsBack optional int
Number of steps in the page history to jump back after execution (the default being one step back). This value overrides any destination specified by the query string.
ADMIN_ReturnToMenuItem optional string
Jumps back to the menu item with this alias after execution. This value overrides any destination specified by the query string. If no prior menu item is found with the given alias, then an error is thrown.
ADMIN_Force optional string
Prompts the user with the specified text and the user may answer OK or cancel. If the user chooses OK the sql call will be rerun with the parameter @force set to 1.
ADMIN_Forward optional string
Displays a user friendly message and then forwards to the next menu item.
ADMIN_ForwardLink optional string
Alias of the link to forward to.
ADMIN_ForwardMenuGroup optional string

Alias of the menu group to show after execution (instead of former menu item). This value overrides any destination specified by the query string.

ADMIN_ForwardMenuGroupId optional int

Deprecated. Use ADMIN_ForwardMenuGroup instead.

Id of the menu group to show after execution (instead of former menu item). This value overrides any destination specified by the query string.

ADMIN_ForwardMenuItem optional string
Alias of the menu item to execute after execution (instead of former menu item). This value overrides any destination specified by the query string.
ADMIN_ForwardMenuItemId optional int

Deprecated. Use ADMIN_ForwardMenuItem instead.

Id of the menu item to execute after execution (instead of former menu item). This value overrides any destination specified by the query string.

ADMIN_Message optional string

Displays a user friendly error message to the user.

ADMIN_PasteHtmlFromPopup optional string
Pastes HTML into an HTML editor. See ADMIN_SetFieldValueFromPopup.
ADMIN_SetFieldValueFromPopup optional string
Sets the value of the field specified in the menuitempopup call. Only select this column if menu item is opened in a popup.
ADMIN_ClosePopup optional bit
If this column is anything but NULL the popup will be closed. Only select this column if the menu item is opened in a popup.
Default: The default behavior is to step back inside the popup window and close it if there is nothing to step back to.
ADMIN_ClosePopupAndReloadOpener optional bit

If this column is anything but NULL the popup will be closed and the parent will be reloaded. Only select this column if the menu item is opened in a popup. Avoid using this feature if the opener is a newEdit as that may interrupt the user's ongoing input.

ADMIN_ClearHistory optional any
When the value is not NULL all navigation history is cleared and the user can't navigate back. This is only supported when forwarding to another menu item.
ADMIN_RefreshMenu optional bit
Will trigger a reload of the sidebar if the column is anything but NULL.
Cache optional string
Cache key to be cleared. Supports wildcards.
CacheUserId optional string
Either a user id or '%'.

Clears all caches (e.g. access permissions) related to the specified user id.

Use '%' to clear caches for all users.
CancelButtonText optional string

Changes the text of the Cancel button when used with ADMIN_Force, ADMIN_ConfirmWarning, ADMIN_ConfirmQuestion, ADMIN_ConfirmDelete.

OkButtonText optional string

Changes the text of the OK button when used with ADMIN_ErrorMessage, ADMIN_ConfirmWarning, ADMIN_ConfirmQuestion, ADMIN_ConfirmDelete, ADMIN_InfoMessage, ADMIN_SuccessMessage, ADMIN_Message, ADMIN_Force, or ADMIN_Forward. ADMIN_Force,

SQL Call: Validate parameters

Allows you to validate the SQL parameters before any other SQL is run in the component. This call is only made if the SQL is a stored procedure and Validate parameters is checked.

May modify database: No

Parameters

@Force bit
Set to 1 if the last call to validate parameters used admin_force and the user clicked OK in the OK/Cancel dialog.
@ValidateParams bit
Set to 1 when this call is made.

Resultset: Messages (optional)

Table count: repeated zero or one time
Row count: zero or one row
Columns
ADMIN_Force optional string
Message asking the end user to confirm their parameters.
ADMIN_Message optional string
Message explaining why the parameters are rejected.

Custom access control and logging

SQL Call: Custom access control and logging

Use this call to restrict which entries a user is allowed to view and edit, and to log which entries a user views.

Access to a menu item is normally controlled through functions and roles alone but some entities need more fine grained control. For example, a user may have access to the View Member menu item for normal members but not for members with a protected identity.

The menu items a user visits are always logged (in ADMINLogMenuItem) but for sensitive data you may need to log exactly what entries are viewed. Do the logging in this call as the common ways of viewing data (grid and InfoSQL) are not allowed to modify the database.

If you bind a scalar function instead of a stored procedure to this call then its name must end with '_GrantAccess'.

May modify database: Yes

Resultset: Access permissions

Return whether the user is allowed to visit the menu item with the current parameters.
Table count: repeated exactly once
Row count: exactly one row
Columns
GrantAccess mandatory bit
1 if the user is allowed to view the menu item, 0 if the user should not be allowed to view the menu item.

If 0 then an error will be logged as the user should not have been able to reach the menu item with the given parameters in the first place.