[b]<cfscript>[/b]
[color gray]//define the function[/color]
[b]function isArrayElementDefined(arrayName){[/b]
[color gray]//use try{} to attempt using the array element[/color]
[b]try{[/b]
[color gray]//use the array element and return true[/color]
[b]testVar = evaluate(arrayName);
return true;[/b]
[color gray]//if using it causes an error catch it and return false[/color]
[b]}catch(any test){
return false;
}
}
</cfscript>[/b]