Avoid Powerpoint(/Word) 2010 creating temporary files in working directory

6,147

Solution 1

The reason Office doesnt use the temp folder any more is due to the fact that Office documents are commonly shared and stored on network drives. If I was editing a Word doc off a network share right now and my hard drive died, I could move to another computer and pick up at, or close to, the point when the drive died. If the file was being edited locally, all the work I had done would have been lost.

Solution 2

It isn't possible nor desired for several reasons. While having a temp file will cause unnecessary syncs, that isn't the concern.

As the articles say, this is mainly due to speed(especially larger files) and more importantly, data integrity. What if there was an interruption while Office was writing to your original file?? While easily recoverable, it isn't a gamble I would take as a developer.

I wouldn't worry about the unnecessary activity. I lorem ipsum about 30 pages on my dropbox just now and I hit 6KB/s of network activity for about 5 seconds. . .

Solution 3

The page you are referring to says:

Word gains significant performance speed by placing the temporary file in the same directory as the saved file. If Word placed the temporary file elsewhere, it would have to use the MS-DOS COPY command to move the temporary file from the other directory to the saved location. By leaving the temporary file in the same directory as the saved document file, Word can use the MS-DOS MOVE command to quickly designate the temporary file as the saved document.*

Share:
6,147

Related videos on Youtube

Ben
Author by

Ben

Updated on September 18, 2022

Comments

  • Ben
    Ben over 1 year

    When opening a temporary file, Powerpoint 2010 usually creates a temporary, hidden file called ~$filename.pptx in the same directory. This is undesirable, since it can cause unnecessary activity with e.g. Dropbox. Furthermore, the "Documents" folder should not be used for temporary files -- we have the %TEMP% folder for that.

    So, is it possible to have Powerpoint create its temporary files in %TEMP% instead? The following link suggests that it might not be possible: http://support.microsoft.com/kb/211632

    Also, why does Microsoft not use the %TEMP% folder?

    • Ben
      Ben almost 13 years
      A more modern solution would be to use an alternate data stream.
    • alpha
      alpha almost 12 years
      'tis a shame Dropbox doesn't support excluding filename patterns.
  • Ben
    Ben almost 13 years
    But why does Microsoft not use the %TEMP% folder instead?
  • surfasb
    surfasb almost 13 years
    For situations similar to yours. If it was a document stored offline, WHOLE doc file into %temp%, creating unnecessary traffic. In the case of creating a temp file in the same directory as the working doc, the server has a chance to realize that it is a copy command and thus handle most of the changes server side. In the current model, the worst case scenario is a complete copy. In your suggestion, worst case scenario is they copy it from the network to the local temp, then back to the network.
  • Ben
    Ben almost 13 years
    But the temporary file is not a copy of the original document.