Okay, thanks for that! I didn't really want to have any more loops in my code so I may look into dirplus but possibly just leave it as it is. It's only causing a very occasional issue, hardly ever in fact so it's not too much of a problem really. Thanks again.