Take a look at the ArrayEnumKey() and ArrayEnumValue() UDFs. They might solve the issue more elegantly.
_________________________
There are two types of vessels, submarines and targets.