LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Verify if an executable has been set to "run as admin"? (Win7 64 bit UAC active)

Sorry if this a bit off topic but I was wondering if somebody has already solved this with a CVI / SDK solution.

 

We have some instrument specific commercial software that was colliding with UAC on our Computer Support Group uses as preferred system installs. Eventually, I realized that UAC was the issue and we managed to manually set multiple executables to "Run As Admininstrator". his requires the users to click through one UAC warning  for the topmost executable and the rest of the tagged runasadmin executables inherit elevation.

 

We want to recreate this and my first attempts of randomly locating all of the correct files failed. I was hoping to find a SDK tool that can query files to determine if "Run As Administrator" has been set. I have tried exporting HKEY_LOCAL_MACHINE and HKEY_LOCAL_USER and querying for a  RUNASADMIN value with no luck.

 

It also turns out that my attempts to Google this scenario mostly brings up hits on how to programmatically turn on the "runasadmin" flag instead of querying for current status.

 

All suggestions are appreciated.

 

Greg

0 Kudos
Message 1 of 3
(3,910 Views)

Blakney,

 

Hmmm, this sounds like a Microsoft SDK issue. Did you already check "runas" under the AppID entries in the registry?

Kirk L. | Applications Engineer | National Instruments
0 Kudos
Message 2 of 3
(3,886 Views)

New software from the vendor fixed the situation. Still has my curiosity but for now that is about all. Seems like there should be a way to query this but I have nopt had much luck on finding the the correct key or class to query.

 

Greg

0 Kudos
Message 3 of 3
(3,867 Views)