now as I look at your code.
damn, it's darn similar to mine!

they are like evolution versions of same base udf [Wink]

anyway, the thinking of ours is different.
you coded a working code, I coded a shorter one [Big Grin]

meaning that your udf has larger scopes for variables and thus cutting of strokes affects too many places...
_________________________
!

download KiXnet