Do I assign different or the same class id to 32-bit and 64-bit versions of the same IFilter?

197 views Asked by At

I've implemented my own Microsoft Search IFilter. I need two versions of it - 32-bit and 64-bit for deploying them on corresponding systems.

In case of IFilters for any file extension I can only register one IFilter class id. Which means I can only use one version on any system. So having two class ids seems useless - it only makes the automatic installer more complex.

Do I reuse the same COM class id for both or do I use different class ids?

2

There are 2 answers

0
sharptooth On BEST ANSWER

We ended up reusing the same class id for both versions - since 32-bit programs on Windows 64 see their own copy of HKCR there's no conflict and the same class id is mapped to the right executable in both 32 bit and 64 bit programs. The COM server uses ATL and using the same class id greatly simplified the .rgs registration script.

0
Andrew Keith On

Always use a different CLSID. Dont reuse COM CLSID. You can make them both use the same IID, but always different CLSID.