SetCurrentDirectory question

Tech-Archive recommends: Speed Up your PC by fixing your registry

From: NMD (NMD_at_discussions.microsoft.com)
Date: 09/07/04


Date: Tue, 7 Sep 2004 12:41:03 -0700

This may be a stupid question, but I will ask it anyway, as I can't find
anyone on the web who has ran into the same problem.

If for instance, I am on a machine that has a particular directory(\foo for
instance) secured, i.e. I do not have permissions to look inside, if I
execute the SetCurrentDirectory call to set the current directory to this
directory, I get a failure(5), as expected.

However, if I am on a remote machine that can access this system, if I issue
the SetCurrentDirectory call using the share path, i.e. \\remote_server\foo,
I do not get an error. It does appear that I am being blocked, as this
particular piece of code is unable to list any files in this directory,
however, the SetCurrentDirectory call does not fail, as it did when ran on
the actual machine.

This makes it difficult for us to determine if the failure to find files was
due to the fact that the directory is empty, or we do not have the right
permissions set up.

Any ideas?

Thanks,
NMD