Perhaps you can show us a workbook where we can SEE your UDF in action and point out how it's doing the wrong thing. Click GO ADVANCED and use the paperclip icon to post up a copy of your workbook.