in reply to Re: or with a block
in thread or with a block

Perfect! I like your method. I tried the do first, but I got a "BAREWORD" error for the closedir argument when the directory could not be opened. (I'm using strict). Thanks, Vince