Author Topic: Get AEC ProgID?  (Read 1288 times)

0 Members and 1 Guest are viewing this topic.

kenkrupa

  • Newt
  • Posts: 84
Get AEC ProgID?
« on: April 01, 2020, 11:47:32 AM »
Looking for a way to get such as this (for the current ACA version):
HKEY_CURRENT_USER\Software\Autodesk\AutoCAD\R24.0\ACAD-4104:409\AEC\8.3
It's the 8.3 that I'm look for.
I can do this:
(setq regkey  (strcat "HKEY_CURRENT_USER\\" (vlax-product-key) "\\AEC"))
which gives me this:
"HKEY_CURRENT_USER\\Software\\Autodesk\\AutoCAD\\R24.0\\ACAD-4104:409\\AEC"
but I'm not seeing a way to get that 8.3. Am I missing something?

Jeff_M

  • King Gator
  • Posts: 4087
  • C3D user & customizer
Re: Get AEC ProgID?
« Reply #1 on: April 01, 2020, 12:05:02 PM »
(setq regkey  (strcat "HKEY_CURRENT_USER\\" (vlax-product-key) "\\AEC"))
(setq desc (car (vl-registry-descendents regkey)))

kenkrupa

  • Newt
  • Posts: 84
Re: Get AEC ProgID?
« Reply #2 on: April 01, 2020, 12:55:08 PM »
Yes - thank you!   :smitten:

BIGAL

  • Swamp Rat
  • Posts: 1398
  • 40 + years of using Autocad
Re: Get AEC ProgID?
« Reply #3 on: April 01, 2020, 09:44:23 PM »
This is for CIV3D

Code: [Select]
(setq acApp (vlax-get-acad-object))
  (setq C3D (strcat "HKEY_LOCAL_MACHINE\\"
    (if vlax-user-product-key
      (vlax-user-product-key)
      (vlax-product-key)
    )
    )
C3D (vl-registry-read C3D "Release")
C3D (substr
      C3D
      1
      (vl-string-search "." C3D (+ (vl-string-search "." C3D) 1))
    )
  )
  (vla-getinterfaceobject
    acApp
    (strcat "AeccXUiLand.AeccApplication." C3D)
)
(alert (strcat "version is " c3d "\n\n" "product key is " (vlax-product-key)))
A man who never made a mistake never made anything