Windows 7 compact dynamic VHD
Solution 1:
You can compact a VHD in Windows 7 using diskpart.exe's COMPACT option. Also, if you don't mind a little coding, you can call the CompactVirtualDisk API (I'd post a link to it, but new users can't post hyperlinks - just search MSDN for it if you're interested).
Solution 2:
Using the diskpart command line utility in Windows 7 to compact a VHD file. It works great!