Close Window   
Free Ebook
Got an Excel Question?
Ask it in our Excel forum!
Subscribe for Free Excel tips & more!

Excel Creates Tmp File Everytime Savig File

Forum Register
Search Excel Forum Posts, Tutorials, Macros, Tips, and More

when I save the file, excel creates tmp file in the same dicectory as the
original file is placed. Everytime i click to save this document, it creates
another tmp file.
When I leave Excel application, tmp files are not deleted.
Is it possible to solve this problem?

View Answers     

Similar Excel Tutorials

Export an Excel File to a CSV File
How to export an Excel file to a CSV file (comma separated values file).  This allows you to turn any Excel spread ...
Open Excel Workbook Using VBA Macros
Simple way to open an Excel workbook using VBA and macros. Syntax Workbooks.Open ("File Path") Replace file path w ...
Make Your Macros Available in All Workbooks in Excel
In Excel, you can make it so all of your macros can be easily accessed by any Excel workbook. To do this we need t ...
Remove Personal Information from Excel Files
How to remove all personally identifiable information from an Excel file. When a file is created in Excel, it auto ...

Helpful Excel Macros

Save the Current Worksheet as a New Excel Workbook File
- This Excel Macro will save the currently visible/active worksheet (the one that you see when you run the macro) to a
Excel Macro to Save a Specific Worksheet as a New File
- This Excel Macro allows you to save a specific worksheet within the Excel Workbook to its own new file. You will be a
Save the Current Worksheet as a New File in the Current Folder
- This Excel Macro saves the currently visible worksheet into the SAME folder as the current file. It is different from
Prevent Saving a Workbook under a Different File Name
- This Excel macro prevents the user from saving an excel file or workbook under a different file name. The file can only
Open any Program from Excel
- This free excel macro allows you to open any program on your computer from excel. You can open a media player, file vie

Similar Topics

I use Excel 2003 and within the last few weeks, it started creating a new temp file each time I saved the document. Each time I either do ctrl S or hit the save icon, it saves the file and creates a temp file at the same time. If I save the file 10 times, it creates 10 temp files. The only way to get rid of them is to manually delete them.

Please let me know if there is a setting which needs to be changed. I can't remember changing anything but I sure may have.

Thanks for your help.

We have a shared workbook that is modified and viewed by several people throghout the day. Most users are in read only, but 2-4 might be in write mode at one time. The issue we have is that when someone saves the file, the save process is not completing and the original file is deleted, but the temp file is not renamed.
Excel creates the temp file when the shared workbook is opened up, when the user saves the shared file the original file is deleted and then the temp file is renamed to match the original name. The temp file on the server is occasinoally not being renamed and I have to manually rename the temp file to get the file back. This might happen once a week, month... Yesterday it happened 3 times. This happens occasionally on all of our shared files.
Is there a way to prevent this from happening?

Hello, I'm new here, I don't know if my topic should be here.
I'm using Excel 2000 since few years and I didn't have problems with it, until now.
When I try to modify a file that I've already created, an unexpected window appears telling me that Excel can't save my document with the same name, and it creates a .tmp file.
I need to save the file with se same name, so please help me with this problem.
Thank you in advance.

I am creating an excel file using the 12.0 version of the Microsoft.Office.Interop.Excel dll. After I edit it using office 2007 and save it it becomes unreadable. Also if I rename the file in to .zip then the package is corrupt. This application that creates these excels on the fly using PIA 12.0 but when I open the excels using office 2007 something goes wrong with them. It allows me to save using 2007 but on trying to read the file again it says file is corrupted.

Any know issues with the PIA like that?? I have 2010 installed on the system that creates the files on the fly . Will that make a difference?

Is this a known issue?? Also is there any work around to it?? Any help will be utmost appreciated.

Vipul Unadkat

I'm running Excel 2003 on Windows XP Pro SP2. I'm accessing files on a network drive. I recently changed some security settings in Windows for this particular folder so that only certain people had full control. But everyone can open and save changes to the Excel files within this folder. Since that change, I have seen an enormous amount of temp files, with no extension. The file type says "File" and they are all the same number of characters, like "0EF21000". They open up in Excel just fine. But it seems everytime one of the 43 excel files in this folder is open, it creates a new "File". So in a 12 hour period, access to these 43 Excel files have created 375 "File" files. Prior to this security change, I had seen these files as well. Not everytime a file was opened, but there were still quite a few. But NOTHING like it is now.

What is causing these files to be created??? Can I stop it? I know I could write VBA to clean out all non-XLS files daily, but I'm just trying to figure this out first. Is there a setting in Excel that could be causing this?

I have one user in the office when they save there excel document it creates
a *.tmp file in the current file folder.

Now I checked - Select Tools|General Option and put a check against the
Always Create Backup box before you save the file. But that is not it.

The file created is something like this. dhti4345$0buget200243~.tmp

IF anyone could help that would be greatly appreciated.

I also looked into editing the registry and increasing the cache size but I
would prefer not to do that.

thanks again

Excel when saving a file creates an 8 character random filename which it saves the file into, then after it is complete it renames the temp file name to the actual file name
e.g. myfile.xls --> save file --> temp file called 63ECD800 --> save completes --> myfile.xls deleted --> 63ECD800 renamed to myfile.xls --> save complete. ...explains this

Question - can this TEMP FILE NAME be forced to be something else?
e.g. 63ECD800.tmp or ~myexcelsheet.tmp

Reason - windows desktop search tries to access the temp file while excel is still using it. This causes excel to leave the filename at the temp name.
If I can add a .tmp to the file name I can tell windows desktop search to ignore it.
(this problem seems to be fairly widespread; but most users can't diagnose the fault. I only noticed it one day when the search kept the file locked..)
Unfortunately trying to get the message to the W.D.S. developers is impossible!!

I googled this and did not really turn up anything.

When i use the Pl/sql developer function 'copy to excel', it creates/opens
an excel file for me in the "c.\...\temp" directory".
Now when I am in this file and I use the file/open and file/save commands excel defaults to the "c.\...\temp" directory".

I was wondering if anyone knows how to change the path of the file/open file/save as commands.
I would like to be able to save the file right at the "c:\" directory.

I am using excel2000 and windowxp.
If you need any more info, just ask. I am not very computer literate.


I have two folders which have a bunch of Excel Sheets. Everytime an user opens those files, it creates a file with 8 characters in the name(Eg: FB71F000 ) The file does not have an extension. I have scanned the folders for Virus or any other problem and they seem to be fine.
Everyday, there are about 70+ files created. When I right click on the file and see the properties , I see this

I have attached a screen shot of the folder. I could not attach the files as the forum attachment manager recognizes it as invalid.

Please help.


When a co-worker of mine saves an excel file that I e-mailed her it creates a text file also. Does anyone know why this is happening?

Thanks in advance


I need to build a macro that creates a xml file, having information taken from the excel file and from a database. The fact is that i have an example that shows me how the final file should look like.

An example of a final xml source looks like this one:

So, i have managed to write a vb procedure that creates the exact document, except adding the xmlns and xmlns:xsi atrribuites to the "root" and to "DataFromDB" tags.
I don't know how to do that.
I use Microsoft XML, v5.0.
Could you please help me with this problem?

Here's a little public service (and a reference point for me the next
time this happens if I forget) for people stuck with this type of Excel

You try to save a file (for me, 53Mb excel file using extensive VBA and
autofiltering to an NTFS compressed network share) and get the
following type of message;

Your changes could not be saved to '<<filename>>.xls", but were
saved to a temporary document named 'D933D120'. Close the
existing document, then open the temporary document and
save it under a new name."

You attempt to save and get an error "File not saved".

You close, reboot, wait for a three-quarter moon etc etc, try to open
the temporary file and get the error
"Excel cannot access 'D933D120'. The document may be read-only or

Thank you to those authors describing the above as a garbage bucket
error message, commonly having nothing to do with either read-only
attributes or encryption, which got me thinking "what else could stop a
file being opened".

Here's the solution;
Right click the file

For me, the security settings were blank. It appears that the saving
process which creates this temp file when "overwriting" (actually
creates new file(the temp file above), deletes old, renames new with
old name) an old file fell over before it could apply the relevant
access lists and rename the file.

Simply add yourself as an authorised user for the file, with full

I was then able to open the file, rename etcetera, as described on the
original error message.

As to the original cause of the issue, ie why the save process fell
? - didn't get identical
messages, so not 100%

?Various mentions of antivirus software - unconfirmed

?NTFS compression - takes so long on some large files that a timeout of
some sort occurs- hypothetical only. May depend on network traffic at
the time.

I'm trying to record, and modify the code of, a macro that will be used to
save a file to a new location using a different file type. The problem I'm
having is that the macro now uses the recorded file name for every file that
is copied, regardless of the original file name. The "save as" procedure I'm
doing is to allow the user to click a custom toolbar button in any file to
save that file to a specific location, in the CSV format, while preserving
the original file's name.

Is there code available to preserve the original file name while changing
the file format for any file I choose to save?

Thank you!

Hi Guys

Not sure whether this is the right place to post this or not. I apologise if its not.

I'm trying to create datasource for a word file to look to an excel file, dependant on the filename of the particular excel file. For example

If the excel file was called 1.xls then the datasource would be created based on that file. All this would be done from within Excel.

The final output I am trying to achieve is that you press a button from witin excel, then this goes and creates a new word file connecting it to a datasource created based on the excel file its reading from and then creates a mail merge based on the data in that excel file.

Hope somebody out there can help with this problem.



Hello All,

lately anytime I save an Excel file to a folder, it also creates a .tmp file with alpha numeric file names (e.g. 54405FA). This hasn't always happened but can't figure out what changed on my end. Any thoughts?

For what it's worth, I'm using Excel 2007. Any advice is appreciated.

I have an Apple, with Office X installed, connected to my network of PC's running Office XP. When I open a Excel file (served from a PC across the network) on the Apple, it opens fine with Excel X and I can do all my edits etc without trouble. However when I save back the file to its original location, it creates a shadow file as well with some meaningless information. The saved file when opened on the PC (Excel XP) has lost its VBA project name (and all modules) and therfore can not perofrm any VBA macros unless these are repasted from elsewhere.
Has anyone any ideas to solve this?

Hi very new to macros so please forgive me if this is either stupid or not possible.

I have an 'accounts' WB that i store all business transactions on. Previously when ever we have entered new data we simply 'save as' and edit the date to the filename, this ensures back-ups of the file and obviously we can easily go back and see any changes made between versions.Fine no problem, now the thing is as my knowledge of excel has grown im learning the power of Vlookup between WB's however my current method would not work as the vlookup function would always refer to an outdated version of the file, im sure you get the point. So, is there a way keep the file name the same everytime i save the file but also save a duplicate file labelled with the date that its being saved and save to a speceifc folder? thus having back up files everytime we make new entries. I should probably add this is all stored on dropbox and i dont know if this causes a problem?

Any advice much appreciated.

I have a macro (.xla file) which i use in excel file. I have added this .xla through addin manager. The problem is it works fine as long as it is on one perticular PC. when i transfer it to another PC, it doesnt work. On another PC also i add this .xla in excel addin.
But still it doesnt work. As excel creates an file path (same i .xla path in my original PC) in the formula. when i remove that path then excel understands and search on its local addin. and it works
It is really a headache for me as i supplies this excel sheet along with .xla to many ppl. and everytime i need to do same.
Is there any way where i can add this .xla as a object in excel file itself. and whenever i send this file to anybody it should not creat any problem

Thanks in advance

I have created a macro that creates/saves a text file. The macro will
run on various people's computers and need to create/save the file in
directory that the macro file is located in. By default Excel saves
the file in the directory Excel has been told to put files in.

How do I cause the macro to save the file to the directory the
spreadsheet containing the macro is in?



When I click on Save on an Excel file (click button from the menu or press Ctrl+S) it takes about 10 seconds to save it. Why it takes so much?

My machine: Pentium IV, 3.2 GHz, 2 GB RAM, Excel 2003, WinXP Professional.
File: 1.7MB xls, 19 Worksheets.

I think with such a powerful machine it shouldn't take so much! It's really annoying everytime I save my excel files. Any advice!? Do you need more info to provide?

This started a couple of weeks ago, and since it's my work computer, I have no idea if something got pushed onto my computer that messed up excel, but this is really irritating.

Basically, the main part of my job is that I get excel files from clients, then I have to take specific info from that file and work with it. So I copy/paste it into a new excel file. Recently, I started getting this error message when I tried to save the new file:
"Y:\GEO\Test.xls cannot be accessed. The file may be read-only, or you may be trying to access a read-only location. Or, the server the document is stored on may not be responding."

None of those things are true, as I can save any other kind of file in this location, and I can actually save the original excel file(from the client) in this location. As a matter of fact, the only work around I've found is to actually save OVER the original document with just the data I need. But I can't change the name when I save. I have to do that later, in the file list. It's a very tedious way to work, so I was hoping someone might have an idea what's causing this or how to fix it?!

Hello. I am publishing/saving as webpage a sheet. There are two images that I would like not to be sent. Excel creates a folder in the same directory as the webpage file, that contains the graphics, everytime you save. I would like to stop this part of the process and just send the html file. Is there a manipulation of PublishObjects that I can use?


Hi Guys

Not sure whether this is the right place to post this or not. I apologise if its not.

I'm trying to create datasource for a word file to look to an excel file, dependant on the filename of the particular excel file. For example

If the excel file was called 1.xls then the datasource would be created based on that file. All this would be done from within Excel.

The final output I am trying to achieve is that you press a button from witin excel, then this goes and creates a new word file connecting it to a datasource created based on the excel file its reading from and then creates a mail merge based on the data in that excel file.

Hope somebody out there can help with this problem.



I have an Excel file with more than one worksheet. With the Excel file open,
I want to save one of the sheets as a csv file (but name it with a .txt
extension) and leave the original file open (still as an Excel file) to
continue working with it. I have tried using the SaveAs function and I end
up with both the sheet and the original file with a .txt extension--not what
I want. I have also figured out how to create both files IF I close both
files--also not what I want.

I have searched online and have not come up with any help for this scenario.
I would really appreciate advice from someone who can get this working.

Thank you,

I am trying to prompt the user to save an Excel 2007 file as an '03 file. Here is my code:

file_name = Application.GetSaveAsFilename(FileFilter:="Microsoft Excel file (*.xls), *.xls")
ActiveWorkbook.SaveAs Filename:=file_name
MsgBox "File Saved!"

However, when I close the file and then try to open the .xls file after running the macro, it says:

"The file you are trying to open, ... , is in a different format than specified by the file extension. Verify that the file is not corrupted and is from a trusted source..." (Excel 07)

"This file is not in a recognizable format." (Excel 03)

It does look suspect when I run the macro, because when it asks me to save, it brings up the files name automatically with a .xlsm extension and quotes around the file name. How can I fix this so it will automatically save as an 03 file?