Results 1 to 5 of 5
  1. #1
    Join Date
    Feb 2005
    Posts
    333

    Unanswered: ActiveX Registry

    Does anyone know where to find a list of ActiveX components that are registered on a PC? I have an applilcation that has several new ActiveX components that we currently use a batch file to register (regsvr32 /s mytool.ocx). I want to look at the registry list when the application opens and if the components aren't registered, either register them or prompt the user to run the batch file. The problem is that I don't know how to determine if the components are registered. Eventually the the user will find out when the application crashes. I'm trying to avoid the crash. Any ideas?

  2. #2
    Join Date
    Apr 2004
    Location
    outside the rim
    Posts
    1,011
    If you know shecifically where in the registry the key is that shows the ActiveX is registered, you can look for it and react accordingly. You can also check the References property of the database and see if a particular Reference IsMissing.

    The attached modules will check the version and path to the program file for Adobe, Excel, and Snapshot. This will demonstrate how to check for a specific registry key.

    The functions also include grabbing the username of the currently logged on user (in all Windows platforms up to XP and those using Novell) and give you the current user's Temp Folder, other commonly looked for items in the registry.

    I hereby submitt this to the planned code library the attached modules.

    These should work in any version Access from 97 to present.

    Provided to dbForum by Todd Sutay, SuTech
    Remeber: if you take from the forum, give back

    PS: what does it take to get my name in the bigger, gold letters?
    Attached Files Attached Files
    Last edited by tcace; 04-25-06 at 17:04.
    have fun!

    Todd S.
    click to email


    Independent Development Consultant
    Biz db & reports - SQL, Access, Crystal, Seradex and more
    Small, custom, unique programs - Office, VBA, .NET


    _________________________________________________
    Favorite message from Windows:
    There was an error displaying the previous error message

    Sadly, there was no error number to look up ...

  3. #3
    Join Date
    Feb 2005
    Posts
    333
    If you know shecifically where in the registry the key is that shows the ActiveX is registered
    That is the problem. I don't know where the the components are registered. I know how to access and modify the registry but I don't know where regsvr32 stores the keys. Do all .OCX files get registered to the same location?

  4. #4
    Join Date
    Feb 2005
    Posts
    333

    Found It

    The ocx files are registered in HKEY_CLASSES_ROOT.

  5. #5
    Join Date
    Apr 2004
    Location
    outside the rim
    Posts
    1,011
    Do all .OCX files get registered to the same location?
    Well ..... supposedly, but I trust Microsoft about as far as ... about as far as my annual income is from Bill Gates annual income.

    Here's an idea: search the registry before and after you register the file and compare. That should tell you exacly where the particular component is getting registered and that should be consistent from machine to machine.

    Good luck!
    tc

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •