-DiskState-

DiskState in Scripting by Command Line

Check Disk Space

You can enable DiskState for scripting to return TRUE or FALSE depending on the local volume's free space by the command line. Start DiskState with the argument "/HasVolFree". Example:

C:\Program Files (x64)\DiskState.exe /HasVolFree <driveletter>:<percent>

The <driveletter> is one letter A-Z and specifies which local volume to check. And the <percent> indicates the amount of free space necessary to return TRUE given by a decimal percent value.

A real world example would be:
C:\Program Files (x64)\DiskState.exe /HasVolFree d:20

It checks drive D:\. If this volume contains 20 % or more free disk space, DiskState returns TRUE. Otherwise, DiskState returns FALSE. Note that TRUE has the value of zero (0).

This way, you can make facilitate DiskState from Python and Perl with login scripts and such. The system("...") is useful to accomplish this task.

Open Up Disk Space Analysis Window Directly

You can open up DiskState's space analysis window directly from the command line.

For instance:
C:\Program Files (x64)\DiskState.exe /SpaceView:E

This will open up the DiskState analysis window on drive E:\.

Other command line arguments

Start DiskState with the /? argument to make it show its arguments.

Want Vista behavior under XP?
Use the /customuser:myname1 where "myname1" is a unique identifier for the location of the Clean.ini file etc.