>If I use "\\gvsvr03\groups" as my parameter value ADIR() returns 0. I know that this top directory has nothing but directories list but I know that subdirectories contain html files.
Are you sure you did include the third parameter, "D", in the adir() call? I know I forgot to add it in the code I posted :).