Nice of you to share your script, but (there's always a but) I don't think the Beta forum is the place for it. You should consider posting it in the UDF Library.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.