Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
Hi,
 
I have stuck while retrieving all registered COM components (like references/components in VB IDE) in a single or easy way, So I added "comcat.h" in my project and using "stdComponentCategoriesMgr" I'm getting registered CLSID but it is category wise and implemented all CATID one by one.
EXTERN_C const CATID CATID_Insertable;
EXTERN_C const CATID CATID_Control;
EXTERN_C const CATID CATID_Programmable;
EXTERN_C const CATID CATID_IsShortcut;
EXTERN_C const CATID CATID_NeverShowExt;
EXTERN_C const CATID CATID_DocObject;
EXTERN_C const CATID CATID_Printable;
EXTERN_C const CATID CATID_RequiresDataPathHost;
EXTERN_C const CATID CATID_PersistsToMoniker;
EXTERN_C const CATID CATID_PersistsToStorage;
EXTERN_C const CATID CATID_PersistsToStreamInit;
EXTERN_C const CATID CATID_PersistsToStream;
EXTERN_C const CATID CATID_PersistsToMemory;
EXTERN_C const CATID CATID_PersistsToFile;
EXTERN_C const CATID CATID_PersistsToPropertyBag;
EXTERN_C const CATID CATID_InternetAware;
EXTERN_C const CATID CATID_DesignTimeUIActivatableControl;
Yet I'm not getting all registered COM components CLSID, specially when I search for how many "msxml" versions has been installed in my system.
How do I get all registered COM components CLSID or beside the way about I followed "stdComponentCategoriesMgr".
'
'
Language : Native VC++
Posted 9-Jun-11 21:24pm
Edited 10-Jun-11 6:25am
v2

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

You can manual register the components.For this follow below steps..Example for xml regitration
 
1. Open notepad
2. type
regsvr32 /s %SystemRoot%\system32\msxml.dll
regsvr32 /s %SystemRoot%\system32\msxml2.dll
regsvr32 /s %SystemRoot%\system32\msxml3.dll
regsvr32 /s %SystemRoot%\system32\msxml4.dll
regsvr32 /s %SystemRoot%\system32\msxml6.dll
 
3. save the file as "myname.bat"
4. Double click file
5. All xmls registered
Same way you can register other components
 
** instead of double clicking the batch file you can use system.run command to automate
 
** i used /s to register it silently -- this way you will not see black dos screen popup
 
Thank You
Sanjay
  Permalink  
Comments
nibir.mistry at 13-Jun-11 3:02am
   
Hello Sanjay,
Thanks for your reply , But requirement is different that is "Programmatically determine the how many version(s) of MSXML Parser Installed on my Computer", for example : have you ever seen VB 6.0 IDE ? there has an menu "Project->References" , In "References" dialogbox you can see how many registered COM objects are installed. Like that I want to retrieve list of registered COM objects name. Hope now you understood what I exactly want.
 
With Regards
Nibir mistry

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 250
1 Jochen Arndt 155
2 PIEBALDconsult 150
3 DamithSL 125
4 Afzaal Ahmad Zeeshan 120
0 OriginalGriff 5,695
1 DamithSL 4,591
2 Maciej Los 4,012
3 Kornfeld Eliyahu Peter 3,480
4 Sergey Alexandrovich Kryukov 3,190


Advertise | Privacy | Mobile
Web01 | 2.8.141220.1 | Last Updated 13 Jun 2011
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100