How to create a path to a temporary file on Windows XP/Vista
What is the best way of doing this? tmpnam() returns a path to a file in the root of the drive, which requires administrator privileges on Windows Vista, so this is not an option. ...
What is the best way of doing this? tmpnam() returns a path to a file in the root of the drive, which requires administrator privileges on Windows Vista, so this is not an option. ...
My application deals with e-mails coming from different sources, e.g. Outlook and IMAP mailboxes. Before parsing them, I write them to the temporary directory (keeping them in memory is not an option). While parsing, I might be writing attachments to the temp directory (for example, if they are too large to keep in memory or for full-tex...
I have an application for which log4j logging is configured in a log4j.properties file. Currently, this application runs on UNIX and creates a log file in /tmp. This application needs to run on Windows, and on that platform I would like for it to select the correct temporary directory, which I believe is C:\temp. How can I change my l...
Language used: C# Theory: I want to create a file with the flag FileOptions.DeleteOnClose in a temporary folder. The file is successfully created and I write dato onto it, the next step is to launch the application associated with the file Process.Start(...) and allow the user to inspect the document, finally I close my handle and as so...
I need to generate a unique temporary file with a .csv extension. What I do right now is string filename = System.IO.Path.GetTempFileName().Replace(".tmp", ".csv"); However, this doesn't guarantee that my .csv file will be unique. I know the chances I ever got a collision are very low (especially if you consider that I don't del...
How do you prevent ASP.NET from creating too many temporary files? My website creates gigabytes of temporary files, and that overflows the main partition on the server. How do I prevent this from happening? ...
Hi folks I need to work with some temporary files in my Windows Forms .NET 3.5 application. Those files are opened in an external application that can of course be running for a longer time than my own program. Are there any best practices to make sure these temporary files are cleaned up at any time in order to avoid filling the user'...
Why does vim create <filename>~ files? Is there a way to disable that? If it's for backup (or something), thanks but no thanks, I use git so I don't need your silly backup. Also, these .<filename.with.path.hints>.swp files too. How do I tell vim not to create those? or at the least to cleanup after itself? EDIT wops, duplicate: ...
I have a Perl script that outputs text. I want to import this text into vim, edit it, save it and then exit. On exit, I want the original Perl script to process the edited file. E.G. how crontab -e works when you add a new job. Thanks :) ...
Note that I'm not talking about the compiler-generated "Temporary ASP.NET Files". My web application (ASP.NET MVC) uses Graphviz to generate images that are then fed to the client. This requires the creation of temporary files. What's the best way to deal with these? Is there a way to delete them immediately after they're sent? Should ...
Today I ran WinDirStat to check what is filling up my harddisk. I was surprised to see that this folder contains 4.6 GB (!): C:\Users\...\AppData\Roaming\Microsoft\VisualStudio\9.0\ReflectedSchemas What is the purpose of this folder and the files it contains? Is there a way to get rid of these files in a safe way? Thanks! ...
Hi, In my application my users can import files (pdf/xls/doc) to a table or export them to a folder. Now I want to directly open these files. So far I'm able to : - get an unique name - save the blob file into the generated file - open it The problem is that I don't know how to delete (or update) the file after that the file will be c...
Hi, I have added a menu item in ECB of document of document library. On click of that menu i want to copy that document to my application. For this purpose i need to create a temporary file of the document on the same machine where SharePoint server is installed. Now the problem is that where should i create the temporary file. One solu...
I do alot of bugfixing and implementing new features for several different customers. These customers all report their bugs, change requests and new feature request into our Trac system. Sometimes these requests result in me creating some SQL change scripts, sometimes there are Excel documents or Access databases with testdata, Word doc...
What is the PID assignment policy in Windows? Repeated runs of a process calling _getpid() indicates non sequential assignment (3548,3344,3628,2748,4872,2360). Given the observed non sequential assignment of PIDs, is it possible for two different process with the same pid to be executed closely in time from one another? Obviously the ...
When I navigate to C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files\myfirstproject\202aebd2\f0e764e2\assembly\dl3 in Windows explorer, there are 108 folders with 8 character hexadecimal names. Explorer won't sort this folder by name (or value ). What gives? ...
I've been warned by several people not to store temporary files in the Temporary Internet Files directory. Where would be the best place to store any temporary or log files that my application generates? ...
Hi, I'm building a small webapp on win2003 with asp.net 2.0. I need to create small files that i suppose to be accessable by for the web and the files is suppose to have 10 minute expiration time. I didn't find any support for this in the framework and my other solution that came to mind was to have a schedule job that cleans the file ...
Hi I am using a lot of temporary files in java and my problem is that they do not get deleted. Without having to implement my own handling of temporary file management (not hard I grant you but I am lazy plus with so many things to do If I can save reinventing the wheel for this all the better) is there a way to ensure the temp files on...
I have seen that Windows system use temporary files to increase the performance of some tasks. Those files are marked with the 0x100 attribute when i look at them. I have got the following text from Microsoft: " By using CreateFile() with the FILE_ATTRIBUTE_TEMPORARY flag, you let the system know that the file is likely to be s...