Sign in to follow this  
Followers 0
skafreak_510

Defraging

4 posts in this topic

I'm trying to create a script that will defrag the "C:\" but I'm not sure how to go about doing this. I can't use the "run ()" command. I'd like to avoid mouse clicks and send () as much as possible. What is the best way to go about this?

thank you

Share this post


Link to post
Share on other sites



I'm trying to create a script that will defrag the "C:\" but I'm not sure how to go about doing this. I can't use the "run ()" command. I'd like to avoid mouse clicks and send () as much as possible. What is the best way to go about this?

thank you

If you look in Scripts and Scraps you will find one that someone has made for Windows 2000. This will give you a starting point.


Get Beta versions Here Get latest SciTE editor Here AutoIt 1-2-3 by Valuater - A great starting point.

Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Share this post


Link to post
Share on other sites

Not sure why you cannot use Run()? but XP users just use defrag for script use.

Run(@ComSpec & ' /c Defrag c:')

At a command prompt, just type defrag /? for options.

Share this post


Link to post
Share on other sites

Does the Command Prompt Defrager work the same as the main XP defrager. I spect it should but i just wanted to make sure. I also need to run it as admin and so it runs a schedule. I know how to do the last to things I just need to know if it would even work in command prompt.

Thanks again

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0