# References

Learn how to use references in expressions in ActiveReportsJS.

## Content

`References` are identifiers that are associated with various report elements.

## Data Set Fields

A data set field can be referenced by its name, for example `{UnitPrice}`. At runtime, it is replaced with the field value in the current scope, such as a [Table Row](/activereportsjs/docs/v6.1/ReportAuthorGuide/Report-Items/Data-Regions/Table#table-rows).

## Parameters

A [report parameters](/activereportsjs/docs/v6.1/ReportAuthorGuide/Report-Parameters) can be referenced by its name prefixed with the `@` character, for example, `{@OrderId}`. At runtime, it is replaced with the parameter value.

## Global Values

A global value is one of the following expressions.

* `{&ReportName}` \- returns the name of a report template\.
* `{&ExecutionTime}` \- returns the current date and time\.

For example, the `Report Generated at {&ExecutionTime}` can display the timestamp of the report output.

## Page Numbering

There are two types of page numbering in ActiveReportsJS reports.

* `Global` page numbering is applicable for the entire report.
* `Local` page numbering is applicable for a [data region](/activereportsjs/docs/v6.1/ReportAuthorGuide/Report-Items/Data-Regions) or its group, such as a [Table Group](/activereportsjs/docs/v6.1/ReportAuthorGuide/Report-Items/Data-Regions/Table#table-grouping). You can set the `New Section` property of a data region or grouping to `True` so that they produce independent page numbering.

The following expressions can be used to display global or local page numbering.

* `{&PageNumber}` \- returns the current global page number\.
* `{&TotalPages}` \- returns the global number of pages in the report output\.
* `{&PageNumberInSection}` \- returns the local page number of a data region or group instance\.
* `{&TotalPagesInSection}` \- returns the local number of pages in a data region or group instance\.

For example, the `Page {&PageNumber} of {&TotalPages}` expression evaluates to strings like `Page 1 of 10` at runtime.

## Themes

The following expressions refer to various elements of a [theme](/activereportsjs/docs/v6.1/ReportAuthorGuide/Themes) attached to a report

| Theme value | Expression |
| ----------- | ---------- |
| Light1 color | {Theme.Colors!Light1} |
| Light2 color | {Theme.Colors!Light2} |
| Dark1 color | {Theme.Colors!Dark1} |
| Dark2 color | {Theme.Colors!Dark2} |
| Accent1 color | {Theme.Colors!Accent1} |
| Accent2 color | {Theme.Colors!Accent2} |
| Accent3 color | {Theme.Colors!Accent3} |
| Accent4 color | {Theme.Colors!Accent4} |
| Accent5 color | {Theme.Colors!Accent5} |
| Accent6 color | {Theme.Colors!Accent6} |
| Hyperlink color | {Theme.Colors!Hyperlink} |
| HyperlinkFollowed color | {Theme.Colors!HyperlinkFollowed} |
| Major font family | {Theme.Fonts!MajorFont.Family} |
| Major font size | {Theme.Fonts!MajorFont.Size} |
| Major font style | {Theme.Fonts!MajorFont.Style} |
| Major font weight | {Theme.Fonts!MajorFont.Weight} |
| Minor font family | {Theme.Fonts!MinorFont.Size} |
| Minor font size | {Theme.Fonts!MinorFont.Size} |
| Minor font style | {Theme.Fonts!MinorFont.Style} |
| Minor font weight | {Theme.Fonts!MinorFont.Weight} |
| Image Data<sup>*</sup> | {Theme.Images!\<Image Name>.ImageData} |
| Image Mime Type | {Theme.Images!\<Image Name>.MIMEType} |
| Constant value | {Theme.Constants("\<Constant Key>")} |

<sup>*</sup> To use an image from a theme, set the `Source` property of an [image report item](/activereportsjs/docs/v6.1/ReportAuthorGuide/Report-Items/Data-Visualizers/Image) to `Database`.
