3

I'm trying to call various APIs that are exposed as COM from Silverlight, which is possible only when they are part of a registered automation server and have a respective progid. Word, for example, would be "Word.Application". How do I get a list of all registered servers with their respective progids?

I found the component services snap-in, but I can't find the progids I know about in there. Edit: The snap-in looks like it should be there, I found a properties window that shows applications ids for some COM+ and DCOM applications, but I can't find obvious servers such as Word. The COM+ tree contains only half a dozen entries.

John
  • 6,693
  • 3
  • 51
  • 90
  • 1
    That's just not how it works. You need to know the progid or CLSID first, then COM can find the executable that implements it from the registry. Doing it the other way around is hoping that you know how to use the server properly even if you have no idea what it does. That doesn't work. – Hans Passant Mar 31 '12 at 06:32
  • @passant I think you misunderstood what I want to know, but you helped me nonetheless. What you're saying implies that there is a directory in the registry. So I should be able to get the list from the registry, I only need to know where exactly. Do you know more? – John Mar 31 '12 at 17:03
  • @passant Ah, I think I found it. It's the whole HKEY_CLASSES_ROOT folder in the registry. That's what I wanted to know. – John Mar 31 '12 at 17:07

2 Answers2

6

The list of automation servers appears to be in the registry under HKEY_CLASSES_ROOT. From Silverlight, the name of the key is the progid, the CLDID is the value of subkey called CLSID.

I found this after Hans Passant made a comment to my question mentioning the registry.

John
  • 6,693
  • 3
  • 51
  • 90
1

PrimalScript, by Sapien Technologies Inc., has an object browser that does an excellent job of listing all of the usable COM objects/interfaces on the system.

bshacklett
  • 1,802
  • 5
  • 23
  • 45