Defraggler and scripting

Hi All.

I am new at the forum. I have been using Ccleaner and Defraggler for a while but never posted here, but I have been trying to make a "combo" with defraggler and ccleaner but haven't been succesfull. My idea is to make a batch file that would run defraggler, ccleaner and then shutdown the computer.

I could make it but I have to click on the UAC message before each run, and this is not very confortable, because I want to click on the batch file and leave the computer working.

Any idea about how doing that without shutting down the UAC?

Run the Batch file with UAC privileges, this will allow both programs to run elevated, so only 1 UAC prompt.

Hi Nergal.

I have tried that, but doesn't work. The script executes fastly but nothing happens (a prompt appears and closes very fast, can't see what happens). Do you know how to debug that?

Sorry but my Windows scripting is very basic :)

Run both CCleaner and Defraggler (with the shutdown parameter.) When CCleaner finishes first defraggler will keep running and eventually shut the PC down.