I just can't resize my partition in Windows Vista. I've tried the partion managar, but I get an error: Logical Disk Manager, Access Denied. So I used diskpart.exe, but when I tried to shrink my partition, I got access denied again! Booting in "Safe Mode with Command Prompt" doesn't work, nor does activating the hidden administrator account. How can I shrink my partition?!
I would recommend not using the built in Windows tool for this task, even if you were to resolve the Access Denied problem. Unmovable files such as the page file, etc, usually prevent you shrinking the partition down to the size you actually want anyway.
A way around this is to use a free tool called GParted. Download, burn to a CD and boot into it. You will get a familiar interface which will allow you to play with your partitions. As it runs outside Windows, there no Access Denied errors and nothing stopping the unmovable files from being moved.
You can use GParted or Paragon Partition Manager Express to resize partitions.
Just some comments if you do solve your problem:
Don't erase partitions that you don't recognize, since one might be the restore partition pre-created by your computer manufacturer. Don't also change the order of partitions on the disk. If you create a new partition, make sure it's after all existing partitions. There's also a limit of 4 partitions per hard disk.
Beware: Repartitioning the C drive may cause the computer to become unbootable. Take your backups! It's advised to take an image copy of your C drive, to avoid re-installing Windows. Remember that you can't restore a disk partition image into a smaller partition.
The safest way to resize disks in Vista is by using the in-built Disk Management, which will show you the lowest possible disk size. You can't go below this value unless you defragment the disk so as to move files at the end of the disk to its beginning. But first turn off system restore points and the page-file and clear the recycle bin. Some good free defragmenters are Defraggler and Auslogics Disk Defrag.
If this didn't help as much as you hoped, this means that some unmovable Windows system files were unhelpfully allocated at the end of the disk. Most defragmenters won't touch them, and when I tried one that could, it ended by destroying my hard disk, so I've no recommendation for you. If at this point you're still fully decided on shrinking C, you'll need to re-reinstall windows.
EDIT: At least in one case such a problem was resolved by consolidating empty disk space to the end of the physical disk, probably a bug in diskpart.
Your need to logon with Administrator privilege or select \windows\system32\diskmgmt.msc right-click and "Run as administrator".