Fun With Batch Files?

Hi everyone,

I'm really not sure if this is a CCleaner issue or a windows issue, but here it goes.

I've created the following batch file, and put it in the startup folder for the All Users folder on a Win XP machine.

"

echo off

cls

cd c:"program files"\CCleaner

CCleaner /auto

"

Here is the reason I'm doing this. I'm currently at war with the classic "Clean temp files in a multi user (upwards of 500) environment" issue. My plan was to use the above batch file to have each users temp files cleared on startup.

This doesn't seem to work though. When somebody logs on, the batch screen runs, and then closes. Temp files aren't deleted though. I'm fairly sure the batch works though, as when I go to start --> run and run the batch file there, the temp files are erased.

Thoughts on this? Or is this more of a windows issue then a CCleaner issue.

A simple solution without messing with the batch file is to create a link in the All Users startup area in the registry under "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run", or even easier create a shortcut in: "C:\Documents and Settings\All Users\Start Menu\Programs\Startup"

Two suggestions

  1. You can select 'Run CCleaner when computer starts' in Options > Settings.
  2. If you want to go ahead with the batch script, make sure it works. The script you have given here certainly won't work. Use cmd command prompt for testing the script.