
Moving folders from within a VBA macro in Word 2000
Dear All,
I am having difficulty writing a macro to move a folder full of files from
one network drive to another. I'm using a VBA macro in Word 2000 on
Winnt4.0.
I've tried using the filesystemobject.movefolder method and the
folderobject.move method and both give the following result:
Run-time error '70' permission denied.
The code works fine to move folders between two drives on my local machine
("C:\" etc) but not on networked drives ("H:\") etc. I know that I have the
relevant file permissions to the drives (I've checked share and fs level
permissions, and I can drag and drop the folders manually).
Ideally, I'd like to access these folders and files using UNC pathnames
rather than mapped drives, but I can't work out how to do this using the
filesystem object (whose only properties is the drives container and the
drives count!)
Is there another way of moving folders? Could I maybe run a CommandPrompt
command to do it?
Any help greatly appreciated.
Tony Woodhouse
I.T. Manager - Brethertons Solicitors - England