Thank you Allen for the reply.. I knew it was the pipe but could not figure out how to get it working. Your solution is correct. I also got to looking at the UDF forum AFTER I wrote this.

Thanks again
MIke