2

ThumbnailProvider and 64bit Operating Systems

Posted by Jeremy on September 30, 2009 in General, Software |

I’ve been working on Explorer extensions for the software company I develop for, Cimatron/Gibbs. I first worked up a Preview Pane extension, and while the general code was easy enough to get working, extracting data from our files wasn’t as trivial as I would have liked due to the way that we pack the preview data, and that playing with byte arrays just isn’t all that fun in in C#, but it worked, and it looked good.

Management then wanted me to hook into the Vista & Windows 7 thumbnailing interface.  I did some research and found a number of great articles on the net about using ThumbnailProvider and IInitializeWithStream. I even found a great blog with a easy step by step to get it working.  GREAT, or so I thought.  I spent a few days trying to figure out why my Explorer hook wasn’t loading.  I was nearly pulling my hair out trying to get things working properly.  At the end of last week I decided to throw a hail mary and sent an email to Ben, the author of the blog I had found.  He was quite prompt in his reply and tried to help as much as he could. We narrowed it down to a 64 bit system issue and as he didn’t have a 64bit system to test this on, that was about as much as he could help me.

Last night, working late on some images for another project I was working on, I went to save the image from Photoshop to a bmp to compile it into an application.  As I went browsing directories, I suddenly saw preview images for my files.  WHAT?! Suddenly after a day of not working on the project at all and more or less shelving it for now, it starts to show life?  Sort of.

After some deeper googling, I found that when I registered my assembly with RegASM, I did only half of the work.  It turns out that there is also a 64bit version of RegASM that I needed to register my assembly against.  I built the extension with the “Any CPU” setting and was able to register the assembly against both versions of RegASM and now I have wonderful thumbnails from within Explorer.

What I've been working on

I know I’ve emailed him thanking him for his assistance in trying to help me debug this, but I’d like to publicly thank Ben for the time he took to help me with this issue.

Update:  Earlier this afternoon I showed this project to a very successful reseller of ours from Japan.  He was impressed with it and asked for a picture of it so that he could show it to his bosses and other people at his company, so I sent him off the email.  As I was leaving the office at 5:30 I ran into my boss.  She told me he was VERY impressed with the project, so much so that they were going to include it in their marketing materials for the upcoming release in Japan.  That made me smile a little.  Then she told me that after OUR sales team heard that THEIR sales team was going to use it in marketing materials, that OUR sales team was going to do something with it as well, possibly issuing a press release.  Don’t get me wrong, I love the fact that my work in the company is valued, but it just feels kind of weird when a project of mine that took a few days ( and only because of a 64bit issue ) is given this kind of attention compared to a project that took me nearly 6 months to complete, and was barely passed oven in release notes, let alone marketing material.  I’m not complaining, it’s just odd what a Sales/Marketing team will latch on to and run with sometimes.

Tags: , , ,

2 Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Copyright © 2009-2024 Code Monkey Codes All rights reserved.
This site is using the Desk Mess Mirrored theme, v2.5, from BuyNowShop.com.

Get Adobe Flash player