< Day Day Up > |
Get(CalculationRepetitionNumber)Category: Get Syntax: Get ( CalculationRepetitionNumber ) Parameters: none Description: Returns the current repetition number of a calculation field. If the calculation is not set to allow more than one value, Get (CalculationRepetitionNumber) returns 1 . Examples: Get ( CalculationRepetitionNumber ) Returns 1 in the first repetition of a repeating field, 2 in the second repetition, and so on, up to the maximum number of repetitions the field has been defined to hold. A calculation field defined to hold 5 repetitions and that has the following formula: Get (CalculationRepetitionNumber) ^ 2 returns the repetition values 1 , 4 , 9 , 16 , 25 . Comments: Get (CalculationRepetitionNumber) is really nothing more than the repetition number. It's the repeating field analog of the Get (PortalRowNumber) and Get (RecordNumber) functions. You can use the repetition number in conditional tests involving repeating fields. For instance, the following formula: If (Get (CalculationRepetitionNumber) < 4; "foo"; "bar") returns a repeating calculation field with values foo , foo , foo , bar , bar , etc. |
< Day Day Up > |