What type is your Global_Logic you are referencing?
And what type of the string are you returning?
I'm not really sure what the global logic does, as I'm just trying to help the programmer solve the issue, I believe it is procedural. But I do know the line the error occurs on is just a simple conversion from numeric to Alpha.
The global logic really isn't the problem though, I checked that first. I watched as the function genned without problem, a new logic was added with only a comment line, and then the function failed to gen, referencing an error in a completely different logic in a different part of the funtion. When the logic with the comment line was removed however, the function genned without problem once again.