CheckFormAgainstArray - CommonArrayFunctions
Member of: CommonArrayFunctions Script
Checks to see if the passed in form is in the array. (Basically wrapping a find call with a couple of additional checks to handle None)
SyntaxEdit
bool Function CheckFormAgainstArray(Form FormToCheck, Form[] ArrayToCheck, bool returnValueIfArrayIsEmpty = false) global
ParametersEdit
- FormToCheck: The Form to look for
- ArrayToCheck: The Form array we are looking in
- returnValueIfArrayIsEmpty: If the array is empty, return this.
- Default: false
Return ValueEdit
- True: If the Form is in the array
- False: If the Form is not in the array
- False: If Form is None
- returnValueIfArrayIsEmpty: If ArrayToCheck is Empty/None
ExamplesEdit
if CommonArrayFunctions.CheckFormAgainstArray(Car, FuelEfficientCars)
Debug.Trace("The car is fuel efficient!")
endIf