Solved

Win 98 Temp Directory

Posted on 2000-02-16
7
251 Views
Last Modified: 2013-12-28
Could anybody pls tell me what is this C:\Temp directory which all the time grows by itself and stores the information whatever file I opened on whatever date..

I would really appreciate the help

Regards
0
Comment
Question by:rnarang98
  • 4
  • 3
7 Comments
 
LVL 6

Accepted Solution

by:
bartsmit earned 100 total points
ID: 2527649
windows stores temporary files in the folder that your temp environment variable points to. By default this is c:\windows\temp but if you have a SET TEMP=C:\TEMP line in your autoexec.bat then it will use the c:\temp folder instead.

Any program that stores a file in the temp folder should remove it when it is no longer needed. However programs sometimes crash and leave the file(s) behind.

You can safely delete files in the temp folder. add this line to your autoexec.bat:
ECHO Y | DEL C:\TEMP


0
 

Author Comment

by:rnarang98
ID: 2527798
Adjusted points to 50
0
 

Author Comment

by:rnarang98
ID: 2527799
I can see in my autoexec.bat.. doesnt say anything. I am on WINNT m/c .. I checked in.. My Computer Environment variable though.. There I guess we have two types of variables -- System Variables and User Variable..

In User Variable I have a variable called TEMP as well as TMP.. Both has a value of C:\TEMP.. If I doubleclick on it.. it gives me the value of
%SystemDrive%\TEMP

I am kinnda confused..
1) what are System variable and User Variable?
2) TEMP and TMP.. whats the difference?
3) what does %SystemDrive%\TEMP means?
4) what is this % sign?

As you say ..programs sometimes crash and leave the file(s) behind. It seems to me .. program Like Flash-- from Macromedia also crashes.. and always leave a file in my temp folder..

Would really appreciate this help

Best Regards
0
Do email signature updates give you a headache?

Do you feel like you are constantly making changes to email signatures? Are the images not formatting how you want them to? Want high-quality HTML signatures on all devices, including on mobiles and Macs? Then, let Exclaimer solve all your email signature problems today.

 
LVL 6

Expert Comment

by:bartsmit
ID: 2530488
%systemdrive% is a variable that is expanded by NT to point to the system drive (usually c:)

System variables are the same for all users while user variables are user specific.

Since you share this folder with other users on the same machine, you cannot delete all the files.

TEMP and TMP are the two environment variables that programs may use to find out where to place their temporary files.

If the machine is running low on disk space then you should ask an administrator to clear out the temp folder. If not, just leave it ;-)

BTW I assumed you were using win98 since this is the win98 forum...
0
 

Author Comment

by:rnarang98
ID: 2531455
Thanks for the reply. Sorry for posting WINNT query in WIN98.. Firstly that was my mistake .. Sorry about that.. and then I didn't find any WINNT discussion forum.. anyway.. sorry for this.. I would appreciate if you can clarify me a little bit more for which I am increasing my points on this question..

When you say TEMP and TMP are two different env. variables.. Where in application do we mention which env variable to look for ..  

why 2 variables when anyway they are pointing to same dir   c:\temp

does windows put files in temp dir or any specific application..

if application -- why application need to put anything in temp dir?? and actually what does it usually puts in there?

if windows -- why does windows need to put anything in temp dir

i make an application say a JAVA APPLET..now where do i mention to put anything in temp dir? why should i do that? and what should i put in temp dir actually?

I would really appreciate if you can clarify on these issues as well..

Best Regards
0
 

Author Comment

by:rnarang98
ID: 2531456
Adjusted points to 100
0
 
LVL 6

Expert Comment

by:bartsmit
ID: 2532898
TEMP and TMP are just conventions for programmers from the dark days of DOS programs. Instead of assuming that an application was free to create temp files in its own directory the software developers would look at the variables to see if there was a preferred directory. This would allow the application directory to be made read-only as well.

NT follows these conventions and assigns the TEMP directory on the system drive to these variables. both are needed because not everybody agreed on the name of the variable.

Temp files are needed for lots of reasons. If you open a file for editing, it is good practice for the application to make a temporary copy and operate on that. This ensures that the original is safe if the user decides to discard the editing session.

Windows creates temp files for many reasons. Don't forget that 'windows' is really a GUI with a suite of small applications (wordpad, paint, etc.)

Java applets are a bit different since they a) usually don't work with documents and b) won't have access to the file system since they operate in the Java sandbox which doesn't allow access to files.

If you write an *application* in java, then you'll find that you'll need to create temporary files as well.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
wallpaper slide show - Windows 8 4 32
Delayed service start 8 28
Microsoft Surface -- Factory Reset ? 5 18
Is there a driver update utility? 8 44
A few months ago I had an issue with LaserJet 1020 printer which was installed to XP and Windows 7.  It was installed to XP and working, but when I tried to connect from a Windows 7 PC, it would attempt connection and then fail.  Sometimes the Spool…
Storage devices are generally used to save the data or sometime transfer the data from one computer system to another system. However, sometimes user accidentally erased their important data from the Storage devices. Users have to know how data reco…
This video Micro Tutorial explains how to clone a hard drive using a commercial software product for Windows systems called Casper from Future Systems Solutions (FSS). Cloning makes an exact, complete copy of one hard disk drive (HDD) onto another d…
This Micro Tutorial hows how you can integrate  Mac OSX to a Windows Active Directory Domain. Apple has made it easy to allow users to bind their macs to a windows domain with relative ease. The following video show how to bind OSX Mavericks to …

895 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now