[]
        
(Showing Draft Content)

Values

Common Values are run-time values available for every property in each report. You can directly drag and drop these common values from the Report Explorer onto the design surface or add and modify the values from the Expression Editor. Following is a list of the values that you can see under the Values node in the Report Explorer and the Expression Editor.

COMMON VALUES

Value

Description

Current Date and Time

Displays the current date and time. The date and time are displayed in MM/DD/YYYY and HH:mm:ss 12-hour format. It can be used in the Page Header and Page Footer.

{&ExecutionTime}

Page Number

Displays the current page number. It can be used in the Page Header and Page Footer.

{&PageNumber}

Total Pages

Displays the total number of pages. It can be used in the Page Header and Page Footer.

{&TotalPages}

Page N of M

Displays the current page number (N) and the total number of pages (M) in the format 'N of M'. It can be used in the Page Header and Page Footer.

Page {&PageNumber} of {&TotalPages}

Page Number (Section)

Displays the current page number of the section to which the function belongs. The section can be a report or a data region.

{&PageNumberInSection}

Total Pages (Section)

Displays the total number of pages of the section to which the function belongs. The section can be a report or a data region.

{&TotalPagesInSection}

Page N of M (Section)

Displays the current page number (N) and the total number of pages (M) in the format 'N of M' of the section to which the function belongs. The section can be a report or a data region.

Page {&PageNumberInSection} of {&TotalPagesInSection}

Report Name

Displays the name of the report.

{&ReportName}

User ID

Displays the User ID of the user previewing the report.

{User!UserID}

User Language

Displays the Language of the user previewing the report as per system settings.

{User!Language}

User Context

Use only with the function.

e.g. UserContext.GetValue("name"), UserContext.NumberToWords(123).

{UserContext}

Current Textbox Value

This variable will be replaced with the current textbox(es) value(s) when saved.

{$$$}

OPERATIONS

Arithmetic

Value

Description

Syntax (S) and Example (E)

^

Raises a number to the power of another number.

S: <Number1> ^ <Number2> E: {Quantity ^ 2}

*

Evaluates the multiplication of two numbers.

S: <Number1> * <Number2> E: {Quantity * 5}

/

Divides two numbers (numerator by denominator) and returns the quotient as a floating-point number.

S: <Number1> / <Number2> E: {AnnualSales / 2}

\

Divides two numbers and returns an integer result.

S: <Number1> \ <Number2> E: {AnnualSales \ 2}

Mod

Divides two numbers and returns the remainder.

S: <Number1> Mod <Number2> E: {AnnualSales Mod 12}

+

Evaluates the sum of two numbers or concatenates two strings.

S: <Value1> + <Value2> E: {Quantity + 2}

-

Evaluates the difference between two numbers or negates the value of a numeric expression.

S: <Number1> - <Number2> E: {Quantity - 2}

Comparison

Value

Description

Syntax (S) and Example (E)

<

Returns True if the left operand is less than the right operand.

S: <Value1> < <Value2> E: {AnnualSales < 80000}

<=

Returns True if the left operand is less than or equal to the right operand.

S: <Value1> <= <Value2> E: {AnnualSales <= 80000}

>

Returns True if the left operand is greater than the right operand.

S: <Value1> > <Value2> E: {AnnualSales > 80000}

>=

Returns True if the left operand is greater than or equal to the right operand.

S: <Value1> >= <Value2> E: {AnnualSales >= 80000}

=

Returns True if the left operand is equal to the right operand.

S: <Value1> = <Value2> E: {AnnualSales = 80000}

<>

Returns True if the left operand is not equal to the right operand.

S: <Value1> <> <Value2> E: {AnnualSales <> 80000}

Like

Compares two strings and returns True if the left operand is the same as the right operand.

S: <String1> Like <String2> E: {FirstName Like "A*"}

Is

Compares two object references and returns True if the left operand is identical to the right operand.

S: <Value1> Is <Value2> E: {FirstName Is LastName}

Concatenation

Value

Description

Syntax (S) and Example (E)

&

Returns the string value of the concatenation of two expressions that individually evaluate to strings.

S: <String1> & <String2> E: {FirstName & " " & LastName}

+

Evaluates the sum of two numbers or concatenates two strings.

S: <String1> + <String2> E: {FirstName + " " + LastName}

Logical / Bitwise

Value

Description

Syntax (S) and Example (E)

And

Returns the logical conjunction of two Boolean expressions, or the bitwise conjunction of two numeric expressions.

S:<Value1> And <Value2> E: {AnnualSales > 80000 And Quantity > 5}

Not

Returns the logical negation of a Boolean expression, or the bitwise negation of a numeric expression.

S: Not <Value> E: {Not AnnualSales > 80000}

Or

Returns the logical disjunction of two Boolean expressions, or the bitwise disjunction of two numeric values.

S: <Value1> Or <Value2> E: {AnnualSales > 80000 Or Quantity > 5}

Xor

Returns a logical exclusion operation of two Boolean expressions, or a bitwise exclusion of two numeric expressions.

S: <Value1> Xor <Value2> E: {AnnualSales > 80000 Xor Quantity > 5}

AndAlso

Returns the logical conjunction of two Boolean expressions by skipping the evaluation of the other expression if the evaluation of the first expression provides the result.

S: <Boolean1> AndAlso <Boolean2> E: {AnnualSales > 80000 AndAlso Quantity > 1}

OrElse

Returns the logical disjunction of two Boolean expressions by skipping the evaluation of one expression if the evaluation of the other expression provides the result.

S: <Boolean1> OrElse <Boolean2> E: {AnnualSales > 80000 OrElse Quantity > 1}

Bit Shift

Value

Description

Syntax (S) and Example (E)

<<

Performs an arithmetic left shift on a bit pattern.

S: <Number1> << <Number2> E: {RegionID << 2}

>>

Performs an arithmetic right shift on a bit pattern.

S: <Number1> >> <Number2> E: {RegionID >> 2}

DOCUMENT MAP

Value

Description

Expression

Path

Returns the path of the TOC level.

{DocumentMap.Path}

Constants

Function

Description

vbBack

Backspace character

vbCr

Carriage return character

vbCrLf

Carriage return-linefeed combination

vbBinaryCompare

Performs a binary comparison.

vbFalse

False

vbFirstJan1

Start with a week in which January 1 occurs (default).

vbFirstFullWeek

Start with the first full week of the year.

vbFriday

Friday

vbFormFeed

Not useful in Microsoft Windows or on the Macintosh

vbGeneralDate

Display a date and/or time. For real numbers, display a date and time. If there is no fractional part, display only a date. If there is only an integer part, display time only. The date and time display is determined by your system settings.

vbKatakana

Converts Hiragana characters in a string to Katakana characters. Applies to Japan only.

vbLf

Linefeed character

vbLinguisticCasing

Converts characters to use linguistic rules for casing instead of file system rules for casing.

vbLongDate

Display a time by using the long date format specified in your computer's regional settings.

vbLongTime

Display a time by using the long time format specified in your computer's regional settings.

vbLowerCase

Converts the string to lowercase characters.

vbMonday

Monday

vbNarrow

Converts wide (double-byte) characters in the string to narrow (single-byte) characters. Applies to East Asia locales.

vbNewLine

Platform-specific new line character; whichever is appropriate for the current platform.

vbNullChar

Character having value 0

vbNullString

Not the same as a zero-length string (""); used for calling external procedures.

vbObjectError

User-defined error numbers should be greater than this value. For example: Err.Raise Number = vbObjectError + 1000

vbProperCase

Converts the first letter of every word to uppercase and the remaining characters to lowercase.

vbSaturday

Saturday

vbShortDate

Display a date by using the short date format specified in your computer's regional settings.

vbShortTime

Display a time by using the short time format specified in your computer's regional settings.

vbSimplifiedChinese

Converts traditional Chinese characters to simplified Chinese characters.

vbSunday

Sunday

vbTab

Tab character

vbTextCompare

Performs a textual comparison.

vbThursday

Thursday

vbTuesday

Tuesday

vbTraditionalChinese

Converts simplified Chinese characters to traditional Chinese characters.

vbTrue

True

vbUpperCase

Converts the string to uppercase characters.

vbUseDefault

Converts the string to lowercase characters.

vbUseSystem

Use NLS API setting

vbUseSystemDayOfWeek

Use the day of the week specified in your system settings for the first day of the week.

vbVerticalTab

Not useful in Microsoft Windows or on the Macintosh.

vbWednesday

Wednesday

vbWide

Converts narrow (single-byte) characters in a string to wide (double-byte) characters. Applies to East Asia locales.

Information

Function

Description

IsArray

Returns a Boolean value indicating whether a variable points to an array.

IsDate

Returns a Boolean value indicating whether an expression represents a valid Date value.

IsNothing

Returns a Boolean value indicating whether an expression has no object assigned to it.

IsNumeric

Returns a Boolean value indicating whether an expression can be evaluated as a number.

IsError

Returns a Boolean value indicating whether an expression is an exception type.

IsDBNull

Returns a Boolean value indicating whether an expression evaluates to the DBNull class.

String

Function

Description

Asc

Returns the ASCII code of the first character in a string.

AscW

Returns the Unicode (wide) character code of the first character in a string.

Chr

Returns the character associated with the specified ASCII code.

ChrW

Returns the Unicode character associated with the specified character code.

Filter

Returns a zero-based array containing a subset of a string array based on a filter criterion.

Format

Returns a string formatted according to instructions in a format expression.

FormatCurrency

Returns an expression formatted as a currency value using the system's currency settings.

FormatDateTime

Returns an expression formatted as a date or time value.

FormatNumber

Returns an expression formatted as a number.

FormatPercent

Returns an expression formatted as a percentage (multiplied by 100) with a percent sign.

GetChar

Returns the character at a specified index of a string.

InStr

Returns the position of the first occurrence of one string within another.

InStrRev

Returns the position of the last occurrence of one string within another.

Join

Returns a string created by joining a number of substrings contained in an array.

LCase

Converts a string to lowercase.

Len

Returns the number of characters in a string.

Left

Returns a specified number of characters from the left side of a string.

LSet

Left-aligns strings within a string variable.

LTrim

Returns a copy of a string with leading spaces removed.

Mid

Returns a specified number of characters from a string starting at a specified position.

Replace

Returns a string in which a specified substring has been replaced with another substring.

Right

Returns a specified number of characters from the right side of a string.

RSet

Right-aligns strings within a string variable.

RTrim

Returns a copy of a string with trailing spaces removed.

Space

Returns a string consisting of the specified number of spaces.

Split

Returns a zero-based array containing a specified number of substrings.

StrComp

Returns a value indicating the result of a string comparison.

StrConv

Returns a string converted as specified (e.g., uppercase, lowercase, proper case).

StrDup

Returns a string consisting of the specified character repeated a specified number of times.

StrLike

Compares strings based on pattern matching.

StrLikeBinary

Performs binary comparison using pattern matching.

StrLikeText

Performs textual comparison using pattern matching.

StrReverse

Returns a string in which the character order of a specified string is reversed.

StrUp

Converts a string to uppercase. (similar to UCase)

Trim

Returns a copy of a string with leading and trailing spaces removed.

UCase

Converts a string to uppercase.

Array

Function

Description

Array

Returns a Variant containing an array. Useful for creating arrays on the fly for looping or passing to functions.

LBound

Returns the smallest available subscript for the indicated dimension of an array.

UBound

Returns the largest available subscript for the indicated dimension of an array.

Split

Splits a string into an array of substrings based on a delimiter.

Join

Combines an array of substrings into a single string with a delimiter.

Filter

Returns a subset of an array based on a filter criterion.

IsArray

Returns True if the variable is an array.

Erase

Reinitializes the elements of an array.

Themes

The following values can be used in expressions:

  • For Major and Minor Fonts: Family, Style, Size, Weight

  • For Colors: Dark1, Dark2, Light1, Light2, Accent1, Accent2, Accent3, Accent4, Accent5, Accent6, Hyperlink, HyperlinkFollowed.

You can also use values from Constants, Report Items, and Datasets as well as Theme images and Constants that are defined in the report.