1
votes

I'm pulling my hair out because I've run into the following problem with one of my clients:

My program uses extensive VBA automation in Word. Macros are saved in a specific Word template that is attached to each document. Some of the macros save the current document to a temporary folder under [User]/AppData/Roaming/... for further processing.

The client is using Win7 with Office2007 (Student edition). On the computer in question I keep getting an error with something like "No permission to save the file" (can't give exact error message because I've translated it from my language to English)

This happens when the macro tries to "SaveAs" the document.

The strange thing is that it happens only 8 out of 10 times - and not all the time. There are no special permissions set for the temporary folder I'm trying to save to.

I've tried changing Word security settings, tried adding the folder to the trusted folders list, tried using a different folder - to no avail.

The client's computer has Norton Antivirus (or Internet Security, I dunno) installed but temporary disabling it didn't solve the problem. (I know I should only be sure after a full uninstall but I can't do that on the client's comp)

Any help is appreciated!


Update: I've since found the exact error message in English: "Word cannot complete the save due to a file permission error."

I'm now looking on the web for similar forum posts but if you guys know something, please let me know. Thanks!

1
So the SaveAs command works correctly 100% of the time on computers other than the one in question? (In other words, you're sure it's just one computer that experiences the problem?)Nick Spreitzer
Yes, it works 100% of the time on every computer I've tested up to now. Except the one mentioned above.Steve
Have you checked for viruses and run a repair of Word / Office on the problem computer?Fionnuala
No. But today I've run into the same problem on another computer. It seems they are both running Windows7 with Office2007 and both are recent installs. I've tested my program thoroughly a few months ago under Win7/Office2007 but there were no issues. Maybe a security update has been issued since then, which is breaking my code?Steve
Silly question (sometimes happens): is a file you use or you overwrite already open ?Coronier

1 Answers

1
votes

Is an antivirus or similar program running? On my development computers many similar problems went away when I changed from (vendor "X" security bundle) to ESET.