Is it possible to do this so that the image is transferred over network connection to some other computer? Or is it even possible to resize the partition on the fly to get rid of unnecessary amount of free space?
There's a command line program to manage your virtualbox session. You can't just copy the image and use it. The utility can clone a disk image so you can reuse it under another virtual machine. It's in the help file. Search for 'clone'. You can then copy the file that contains the new cloned disk image anywhere you like.
There's a utility to zero out the unused portions of your disk. The side effect of using it on a virtual box machine is that the virtual disk image manager will shrink the image file size. Something like this one http://www.heidi.ie/node/6
I don't believe you can resize the partition once it's created.
You can use the VMWare Converter to create a VMware image of a real Windows environment.
I believe you can then use that VMWare VM on Virtual Box. At the very least you can create a new VM in Virtual Box and use the virtual drive files VMWare created.
When you use VMWare Converter you can tell it to save the image to a network drive or a USB drive or something. Sadly it will be as large as your windows partition is. You could always resize your Windows partition to be smaller and then create the VM (that's what I have done in the past).