One possibility would be that you updated to a 64 bit version of Office from a 32 bit version. In some cases, VBA which uses APIs can fail due to the bitness difference. One of the symptoms of that is the failure of common functions like Dir().
What version and build of Access do you have installed?