Office Add-in analysis

Hi,

i am expanding my “Office analysis” analysis and i want to add all installed Add-ins in office.
for that i wrote 2 properties, one for machine and one for user. the user one goes like this:
q: if (exists logged on user) and exists key "HKEY_CURRENT_USER\Software\Microsoft\Office" of registry then (value "FriendlyName" of it) of it whose (exists value "FriendlyName" of it) of (keys of keys of keys of it) of key "HKEY_CURRENT_USER\Software\Microsoft\Office" of registry as string else "No User or no office installed" A: McAfee DLP Print AddIn A: Business Connectivity Services Add-In A: Enterprise Vault Add-in A: Microsoft SharePoint Workspace Proxy for Outlook Add-in A: IronScalesAddIn A: Microsoft VBA for Outlook Addin A: OneNote Notes about Outlook Items A: Microsoft Outlook Social Connector A: Windows Search Email Indexer A: Microsoft Exchange Add-in A: McAfee DLP Print AddIn A: McAfee DLP Print AddIn
you can notice there are some duplicates in the answers, because the same add-in can be installed on several Office applications (for example, “McAfee DLP Print AddIn” is installed in both Excel and Word).

my question here, is can i add to the answer the name of the Parent registry key so i can know which Office application has this Add-In.
the desired solution would be something like:

A: Word - McAfee DLP Print AddIn
A: Excel - McAfee DLP Print AddIn

i have seen on some posts that there is no “parent of” inspector for Registry objects. is there a way around it?

Thanks,

Shlomi

Hi Shlomi,

There is, in fact, an inspector for parent keys. I’m not sure whether that’s exactly what you want, because I don’t seem to have any of those add-ins, but this should do it:

if (exists logged on user) and exists key "HKEY_CURRENT_USER\Software\Microsoft\Office" of registry then (name of parent key of it & " - " & value "FriendlyName" of it) of it whose (exists value "FriendlyName" of it) of (keys of keys of keys of it) of key "HKEY_CURRENT_USER\Software\Microsoft\Office" of registry as string else "No User or no office installed"

If you wanted the name of the key that the FriendlyName is in, rather than the key that THAT key is in, you could use (name of it & " - " & value "FriendlyName" of it) instead.

1 Like

Thanks AJDavis8,

what actually worked was:

q: if (exists logged on user) and exists key "HKEY_CURRENT_USER\Software\Microsoft\Office" of registry then (name of parent key of parent key of it as string & " - " & value "FriendlyName" of it as string) of it whose (exists value "FriendlyName" of it) of (keys of keys of keys of it) of key "HKEY_CURRENT_USER\Software\Microsoft\Office" of registry as string else "No User or no office installed" A: Outlook - Microsoft Access Outlook Add-in for Data Collection and Publishing A: Outlook - Microsoft SharePoint Server Colleague Import Add-in A: PowerPoint - OneNote Notes about PowerPoint Presentations A: Word - OneNote Notes about Word Documents T: 3.416 ms
(the key name was 2 levels up and i had to convert to string value), but you definitely got me in the right direction - Thanks!

1 Like

To work in the context of user (as the client runs as local\ system), this woud be better code -

q: if exists keys “Software\Microsoft\Office” of current user keys (logged on users) of registry then (name of parent key of parent key of it as string & " - " & value “FriendlyName” of it as string) of it whose (exists value “FriendlyName” of it) of (keys of keys of keys of it) of keys “Software\Microsoft\Office” of current user keys (logged on users) of registry as string else “N/A”

Hi Nick,

i actually tested that to see which is more efficient, and on your query i received the following error:
E: The expression could not be evaluated: Windows Error 0x522: A required privilege is not held by the client.
so if i understand correctly, your query would work only if the user is a local admin, which is not the case in most of our computers.

To test in Fixlet Debugger, click ‘Debug’ - ‘Evaluate Using’ - ‘Local Client Evaluator’

When you add as a Retrieved Property, it will retrun same results as Fixlet Debugger when run as local client (as above)

Thanks Nick,

i was curious, so i added another property with what you suggested, and compared both.
you are right, of course, that the BES client is running as SYSTEM, so querying "“HKEY_CURRENT_USER” should result in the System Current user branch.
it seems that the results are identical, which is puzzling. Just saying…