Function overview
Prototype
NextValue (
valueIter )
Parameters
valueIter A value iterator
Description
Tags:
ValueIterator
This function uses a value-iterator "object" that is created with the ValueIterator function.
This function provides a forward iterator over the list of values.
The backward iterator is called PrevValue().
Examples
Sample input
NextValue( ValueIterator( "ape¶bear¶jam" ) )
Sample output
ape
Function code
Let( [ currentIdx = _getVariable( valueIter; 1 );
values = _getVariable( valueIter; 0 );
numValues = _getVariable( valueiter; 2 ) ];
If ( currentIdx <= numValues;
Let( [ currentIdx = currentIdx+1;
nextValue = GetValue( values; currentIdx );
jnk = _setVariable( valueIter; 1; currentIdx )
];
nextValue
)
)
)
// ===================================
/*
This function is published on FileMaker Custom Functions
to check for updates and provide feedback and bug reports
please visit http://www.fmfunctions.com/fid/166
Prototype: NextValue( valueIter )
Function Author: The Shadow (http://www.fmfunctions.com/mid/34)
Last updated: 24 December 2008
Version: 1
*/
// ===================================
Let( [ currentIdx = _getVariable( valueIter; 1 );__LITBR__ values = _getVariable( valueIter; 0 );__LITBR__ numValues = _getVariable( valueiter; 2 ) ];__LITBR____LITBR__ If ( currentIdx <= numValues;__LITBR__ Let( [ currentIdx = currentIdx+1;__LITBR__ nextValue = GetValue( values; currentIdx );__LITBR__ jnk = _setVariable( valueIter; 1; currentIdx )__LITBR__ ];__LITBR__ nextValue__LITBR__ )__LITBR__ )__LITBR__)__LITBR____LITBR__// ===================================__LITBR__/*__LITBR____LITBR__ This function is published on FileMaker Custom Functions__LITBR__ to check for updates and provide feedback and bug reports__LITBR__ please visit http://www.fmfunctions.com/fid/166__LITBR____LITBR__ Prototype: NextValue( valueIter )__LITBR__ Function Author: The Shadow (http://www.fmfunctions.com/mid/34)__LITBR__ Last updated: 24 December 2008__LITBR__ Version: 1__LITBR____LITBR__*/__LITBR__// ===================================
Login or register to comment
Create a new account with fmcustomfunctions.com or login to post a comment.