THIS IS THE WRONG WAY TO DO THIS - at least, in most cases.
If you call the GetThumbnailImage() method, as stated in the documentation, it will return the thumbnail image EMBEDDED IN THE IMAGE resized to the size you requested.
In many cases, this isn't what you want. For example, let's say I take a photo from my Minolta 7D, it is 2000x3006 pixels, with an 100x150 embedded thumbnail.
I now request a "thumbnail" image that is 400x600. It will take the 100x150 image and blow it up to be 400x600. It will not take the large image and scale it.
To do that, you need to create another image, and draw the large image on to it and save the new image.
The only case where this will work is if the image you want is smaller than the one that is embedded, or if there is no embedded image. If you are using this generically, then you need to consider someone uploading a 2K x 3K image with a 16x16 embedded thumbnail.. Not pretty when you blow it up to 100x150 or whatever.
If you want to confirm this problem, just blow up an image to the original size using this method. Depending on the make of the camera you used to get the image, it will either look good or look like crud.
Chert
www.traderhut.com