Share via


Length Element (View)

This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This page may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Returns the length of the string within the element. The value returned can be divided by, or subtracted from, the value of the Div or Sub attribute, respectively.

<Length
  Div = "Integer"
  Sub = "Integer">
</Length>

Attributes

Attribute

Description

Div

Optional Integer. Specifies how much to divide the resulting value by.

Sub

Optional Integer. Specifies how much to subtract from the resulting value.

Child Elements

Column, GetVar

Parent Elements

Numerous

Occurrences

Minimum: 0

Maximum: Unbounded

Remarks

The following line of code sets a variable named TextLength.

<SetVar Name="TextLength">This is some text that is 
   45 characters long.</SetVar>

The next block of code divides the value of the TextLength variable by 5, to render the number 9.

<Length Div="5">
  <GetVar Name="TextLength"/>
</Length>