Hi all,

Does anyone knows how to extract the ProgID and/or the CLSID from an 
exe/dll/ocx file?

I whish to check if some ocx are registred on my system. I've found the 
following code:
http://groups.google.be/group/borland.public.delphi.thirdpartytools.general/browse_thread/thread/d437d9eba257a0bd/4cfed1624195b497?lnk=st&q=delphi+clsidfromprogid&rnum=13#4cfed1624195b497
var 
  ClassID: TCLSID; 
  strOLEObject: string; 
begin 
  strOLEObject := 'Excel.Application'; {just change on won object name here} 
  if (CLSIDFromProgID(PWideChar(WideString(strOLEObject)), ClassID) = S_OK) 
then 
  begin 
    <application is installed>; 
  end 
  else 
  begin 
    <application is NOT installed>; 
  end 
end; 

It works quite well, but implies that I must know the ProgID (here: 
Excel.Application).  What can I do if I have only the path to the file. Is 
there a way to "read" the ProgID ou CLSID in the file?

Thanks for yor help

Jean-Philippe



[Non-text portions of this message have been removed]

Reply via email to