Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations derfloh on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Excel saves extra copy on server with restricted permissions

Status
Not open for further replies.

LisaBee

Technical User
Jun 23, 2006
18
US
I created a spreadsheet that numerous people throughout the company use that uses vba to save the file to a folder on a server where the folder's permissions are set so that they can save, but cannot delete or move any files saved at that location. When the file is saved, excel ALSO saves a copy of itself at the same location, but this copy/junk file name is a string of letters and numbers. Is there any way to prevent this from happening other than having to change the permissions on the folder?

Thanks! :)
 
That's a temp file. They are created and junked all the time. You generally don't notice them because they appear in a folder to which the user has delete access.

The only way that comes to mind to automate deleting this is to add some VBA to delete any files in the folder that don't contain a certain string. For example, if your existing VBA saves files with names like MonthlyReport_200708, then you could delete any file without "MonthlyReport_" in the name.

If you need help with writing the VBA code to do that, please start by using your macro recorder then posting the resulting code in forum707.

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ 181-2886 before posting.
 

anotherhiggins,

If this code is added in the VBA of the same spreadsheet, it is not going to help, as it would be run by the same people with the same folder permissions (can't delete).

Maybe some maintenance procedure run at the end of the day by someone with permissions?


 
Good point, Stella.

[tt]_____
[blue]-John[/blue][/tt]
[tab][red]The plural of anecdote is not data[/red]

Help us help you. Please read FAQ 181-2886 before posting.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top