473,804 Members | 3,822 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How can I reference the directory that is used for temp files?

I create and assembly and then start a process with it.

I'd like to create it someplace where it would be deleted when the Disk
Cleanup is run.

How can I reference the directory that is used for temp files.

thanks


Nov 28 '06 #1
2 1149
" Franky" <fr********** @a-znet.comschrieb :
How can I reference the directory that is used for temp files.
'System.IO.Path .GetTempPath'.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>
Nov 28 '06 #2
Thanks, works great

"Herfried K. Wagner [MVP]" <hi************ ***@gmx.atwrote in message
news:OA******** ******@TK2MSFTN GP02.phx.gbl...
>" Franky" <fr********** @a-znet.comschrieb :
>How can I reference the directory that is used for temp files.

'System.IO.Path .GetTempPath'.

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://dotnet.mvps.org/dotnet/faqs/>

Nov 29 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
30590
by: S. Han | last post by:
I'm using Directory.GetFiles to enumerate files in a directory. The problem is if you have to enumerate all files + subdirectories recursively, it takes too much memory, and it fails. Is there another way to enumerate files and subdirectories recursively which doesn't take too much memory in CS?
6
4619
by: Martin Bischoff | last post by:
Hi, I'm creating temporary directories in my web app (e.g. ~/data/temp/temp123) to allow users to upload files. When I later delete these directories (from the code behind), the application restarts and all active sessions are terminated. This error is also described in detail here:...
6
1742
by: dave | last post by:
I really have 2 questions regarding the following xml snippet. The xml is a directory representation. <?xml version="1.0" standalone="yes"?> <FileSystem> <Row> <ID>1</ID> <Name>Root</Name> <Directory>Root</Directory> <Dir>true</Dir>
2
17281
by: Rik Hemsley | last post by:
Hi, I am looking for a way to discover the path to the ASP.NET temporary directory, which is called something like 'Temporary ASP.NET Files'. From within an ASP.NET application, I can get the path using IO.Path.GetTempPath(), but I need to do so from outside the application. I am currently using a web service for this, but this is a less than optimal solution: if the web service is unable to start, I don't get the full error message...
2
1253
by: John.Miller | last post by:
I am writing an application inVisual Studio to ease our frontpage publishes. I have the command to publish, but I need to attach the Publish log to an email. Does anyone know how to get the publish log uri in order to attach the email? Here is the code that I am using to publish: Public Function PublishWeb(ByVal webname As String, ByVal sourceurl As String, ByVal destinationurl As String, ByVal webauthor As String, ByVal waemail As...
3
2930
by: Kimera.Kimera | last post by:
I'm trying to write a program in VB.net 2003 that basically deletes all files, folders, sub-folders and sub-sub folders (etc). The program is simply for deleting the Windows/Temp folder contents, removing all the files/folders inside it. The problem i am having is that i can only delete files in the Windows/Temp folder, and i can't delete folders if they contain files, i know that you can't do this.
2
23047
by: =?Utf-8?B?RGFuaWVsIENvcnLDqmE=?= | last post by:
Hi, I've been trying to use Directory.GetFiles() and also DirectoryInfo.GetFiles() to list files on a remote server using "\\server_name\dir_name" like paths. It works fine on a test windows app, but I get an access error message when the code is running on a asp.net app. First I thought it was just a matter of credentials, so I started to use windows authentication and impersonate the current user, but I still got the same message.
6
1968
by: Aussie Rules | last post by:
Hi, In my application I need to write an XML file to disk, but am concerned that permission might be a problem. The file only needs to be written out and used for another reason and can then be deleted. I was thinking about using the windows/system temp directory as the location, as I guess that a directory where my application shouldn't have an
0
1758
by: Alan Meyer | last post by:
I had an unusual problem tonight running makepy to install some Microsoft COM interfaces in a Python 2.5 Windows XP installation created using the ActiveState installer. In earlier versions of Python, the files were generated to: \PythonXX\Lib\site-packages\win32com\gen_py But in my 2.5 installation they were generated to my temp directory, in my case this was:
0
9706
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9579
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10577
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
9150
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6853
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5651
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4299
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3820
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
2991
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.