HOME
TOPICS
ABOUT ME
MAIL

 
Write down the time and date and the name of the program, along with any oddities you encounter. You should also note the name of the folder you've put the program in. (It may seem that programs choose their own folders, but that's not true. You can almost always pick the folder location and name.)
  technofile
Al Fasoldt's reviews and commentaries, continuously available online since 1983

Secrets of installing software safely, Part 2


Aug. 9, 1998

By Al Fasoldt
Copyright © 1998, The Syracuse Newspapers

   Last week I described the secrets of keeping Windows 95 and 98 running smoothly when you install new software. You should keep backup copies of the Windows configuration files, keep a log of what you install, only install one new program at a time and make sure you can get rid of all the traces of a program when you remove it.
   Backups of the Windows configuration files are vital. You don't even need a fancy backup program, although you can use the backup software that comes with Windows if you want. On most Windows PCs, there are only six files that you must back up regularly. They are AUTOEXEC.BAT, CONFIG.SYS, WIN.INI, SYSTEM.INI, SYSTEM.DAT and USER.DAT. (If you use User Profiles -- if, in other words, your single PC allows different users to log on with individual settings -- you also must back up a DAT file named for the user, such as MARY.DAT.)
   You don't even need to know where those files are stored. Just locate them using the Find option in the Start Menu and make copies right from the window that displays the names. If you know how to write a batch file, create one that copies the files. (A sample batch file is shown below, within this page.)
   Keeping a log of programs you install is a simple task. Don't turn it into a project. Write down the time and date and the name of the program, along with any oddities you encounter. You should also note the name of the folder you've put the program in. (It may seem that programs choose their own folders, but that's not true. You can almost always pick the folder location and name.)
   You should install only one program at a time because otherwise you won't know which new program is causing a problem. After installing any program, run it and run all the other programs you normally run and make sure everything is OK. Shut down (using the Start Menu's Shut Down option) and start up again to be certain that there are no conflicts when booting up.
   Now the tough part. Microsoft tried its best to turn stale berries into fresh jam, but the attempt didn't work. Windows 95 and 98 come with an "uninstall" function in the Control Panel, but my guess is that most users have no idea it's there. They just drag program folders into the Recycle Bin, messing up their operating system.
   And there's no need to guess at the second problem with Microsoft's "uninstall" function, because it relies on the competence and good faith of the people who write every program you install. Some programmers don't have the first quality, and so they don't earn the second. (The "uninstall" feature must be designed into the software you install. Windows doesn't do it.)
   So it's up to you to make sure programs can be removed completely. Sophisticated methods of assuring this are beyond the scope of this article. (I recommend Norton Uninstall Deluxe if you want the best protection against rogue installations.) If you do nothing else, be sure you remove programs using the Control Panel's Add/Remove Programs icon.
   If you don't see the a particular program listed there, you might be able to find an "Uninstall" icon for that program in another place. Use Find and look for "uninstall," taking note of the folder location for everything that shows up. See if one of the folders matches the name you wrote down in the log. If so, you've probably found an "Uninstall" icon for that program.
   If you're tried uninstalling a program using the Control Panel or a separate "Uninstall" icon and things are still messed up, you've got a way out -- your backup files. Click the Start button and choose Restart in MS-DOS mode. When the PC boots up in DOS, copy the backup files to their original locations, then type "Exit" and press Enter. That will reboot the PC back into Windows.
     FIXFILES.BAT

 @echo off 

 cls 

 goto top 

 :disclaim 

 echo. 

 echo. 

 echo FIXFILES.BAT by Al Fasoldt, 08-07-98. (Rev. 08-07-98) 

 echo               

 echo Although every effort has been made to make sure   

 echo this program works as described in the help screen,  

 echo the author provides no warranty. Use at your own risk. 

 echo               

 echo For help, run this program with the "/?" parameter.  

 echo A help screen also appears if no parameter is given.  

 echo               

 echo Copyright (C) 1998 by Al Fasoldt. All rights reserved. 

 echo. 

 goto end 

 :top 

 if %1()==() goto help 

 if %1==/? goto help 

 if %1==? goto help 

 if %1==help goto help 

 if %1==restore goto restore 

   

   

 :help 

 cls 

 echo FIXFILES, a system-file restoration utility for Windows 95 and 98. 

 echo   Copyright (C) 1998 by Al Fasoldt. Distribute freely. 

 echo (This uses basic techniques. It is not intended for advanced users.) 

 echo How this works: 

 echo Save this batch file in C:\WINDOWS. 

 echo Make a folder called BACKUP in the main directory (root) of C: 

 echo and use it to store system backups. (Copy them once a week.) 

 echo - Copy AUTOEXEC.BAT and CONFIG.SYS from the root of C: to BACKUP. 

 echo - Copy WIN.INI and SYSTEM.INI from your WINDOWS folder to BACKUP. 

 echo - Copy SYSTEM.DAT and USER.DAT from your WINDOWS folder to BACKUP. 

 echo  (If you have user profiles on your PC, you must also copy 

 echo  a file named for the logon name, such as MARY.DAT, to BACKUP.) 

 echo. 

 echo USAGE: 

 echo Boot up in DOS mode (or click Start, choose "Shut Down..." and then 

 echo. click "Restart in MS-DOS mode"), and then do this in DOS: 

 echo Type FIXFILES or FIXFILES RESTORE and press Enter. 

 echo  FIXFILES 

 echo  (displays help) 

 echo  FIXFILES RESTORE 

 echo  (restores backed-up system files) 

 echo. 

 echo NOTE: Files that are replaced are moved to the backup folder and have 

 echo the letter "B" at the end of their names, such as SYSTEM.DAB. 

 goto end 

   

 :restore 

 :a 

 if not exist c:\backup\nul goto NoBackupDir 

 :b 

 set ini=yes 

 if not exist c:\backup\*.ini goto NoIni 

 :c 

 set dat=yes 

 if not exist c:\backup\*.dat goto NoDat 

 :d 

 set auto=yes 

 if not exist c:\backup\autoexec.bat goto NoAutoExec 

 :e 

 set config=yes 

 if not exist c:\backup\config.sys goto NoConfig 

 cls 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo. 

 echo DON'T RESTORE ANY FILES UNLESS YOU ARE SURE YOU NEED TO. 

 echo PRESS CTRL-C TO CANCEL RIGHT NOW IF YOU DO NOT WANT TO CONTINUE. 

 pause 

 goto DoRestore 

   

 :NoIni 

 cls 

 set ini=no 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo. 

 echo WIN.INI and SYSTEM.INI not found in backup folder. 

 echo. 

 pause 

 if not exist c:\backup\*.dat goto NoDat 

 goto c 

   

 :NoDat 

 cls 

 set dat=no 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo. 

 echo USER.DAT and SYSTEM.DAT not found in backup folder. 

 echo. 

 pause 

 goto d 

   

 :NoAutoExec 

 cls 

 set auto=no 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo. 

 echo AUTOEXEC.BAT not found in backup folder. 

 echo. 

 pause 

 goto e 

   

 :NoConfig 

 cls 

 set config=no 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo. 

 echo CONFIG.SYS not found in backup folder. 

 echo. 

 pause 

 goto DoRestore 

   

 :NoBackupDir 

 cls 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo. 

 echo No backup folder found. 

 echo. 

 pause 

 goto help 

   

 :NoFiles 

 cls 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo. 

 echo Nothing to back up! 

 echo. 

 pause 

 goto help 

   

 :DoRestore 

 if %ini%==no if %dat%==no if %auto%==no if %config%==no goto NoFiles 

 cls 

 echo FIXFILES 

 echo ******** 

 echo. 

 echo Starting file restoration ... 

 c: 

 cd \backup 

 if %ini%==yes copy c:\windows\win.ini c:\backup\win.inb /y 

 if %ini%==yes copy c:\windows\system.ini c:\backup\system.inb /y 

 if %ini%==yes copy *.ini c:\windows 

 if %ini%==yes echo INI files restored. 

 if %dat%==yes attrib -s -h -r c:\backup\*.dat 

 if %dat%==yes attrib -s -h -r c:\windows\*.dat 

 if %dat%==yes copy c:\windows\system.dat c:\backup\system.dab /y 

 if %dat%==yes copy c:\windows\user.dat c:\backup\user.dab /y 

 if %dat%==yes copy *.dat c:\windows 

 if %dat%==yes echo DAT files restored. 

 if %auto%==yes copy c:\autoexec.bat c:\backup\autoexec.bab /y 

 if %auto%==yes copy autoexec.bat c:\ 

 if %auto%==yes echo AUTOEXEC.BAT file restored. 

 if %config==yes copy c:\config.sys c:\backup\config.syb /y 

 if %config==yes copy config.sys c:\ 

 if %config%==yes echo CONFIG.SYS file restored. 

 echo. 

 echo. 

 echo. 

 echo. 

 echo     *** YOU MUST REBOOT NOW! ***