Note that this only works if free space has been zero'ed in the guest OS first. This however does not change the logical disk size. Physical disk image size (the size of the image file on disk as seen by the host OS).
So I thought I would give it a try anyway, either make it or break it. He even wanted the same size (50 GB) for his VDI file as I did for mine, what a coincidence. This guy is also doing it on Linux as host OS.
I found this nice blog post on how to do it with the modifyhd command of VBoxManage. Also, there are plenty of questions here at SU that deal with increasing and decreasing VDI file sizes, but they are all about using Linux as host and Windows as guest.
I searched the world wide web for answers, the VirtualBox forum says you're supposed to use Gparted if you want the easiest method (some mod posted a sticky). It explains disk controllers, SAS, SATA, SCSI, yada, yada, but not what I'm looking for. I've been clicking around the program and reading the Help menu contents, but it's not helping.
But I have changed my mind now, and I want to add another 10 GB. I wasn't sure how much disk space to allocate, so I went for a VDI size of 40 GB and fixed size for increased performance. I have already installed Windows 7 as my first guest. But I think I got the hang of the basics.
I'm new to VirtualBox, and I got a lot to learn. I'm trying to figure out how to change the size of a VDI file.