DigDeep Posted September 10, 2015 Share Posted September 10, 2015 Hi,I have a program that should run at startup and does lots of functions to download, install, check for entries. 90% of the actions require Admin rights. But if I put #RequireAdmin then the code gets added to registry and startup, but does not run in Process. If I remove #RequireAdmin then it runs, but where it is required for admin rights those actions do not work.I even tried to create 2 files. 1st one to hold all the Functions with Admin rights and 2nd one to get Startup part which will call the 1st part. But it does the same. Any suggestions, how can I run the code in Startup and get Admin rights? Link to comment Share on other sites More sharing options...
jguinch Posted September 10, 2015 Share Posted September 10, 2015 With a scheduled task Spoiler Network configuration UDF, _DirGetSizeByExtension, _UninstallList Firefox ConfigurationArray multi-dimensions, Printer Management UDF Link to comment Share on other sites More sharing options...
DigDeep Posted September 11, 2015 Author Share Posted September 11, 2015 @jguinch I tried adding the Scheduled task UDF. But that didn't make any difference. My code still runs at startup Actions could not be performed as the functions need Admin rights.Is there anyways, I can run Startup file with Admin rights? Link to comment Share on other sites More sharing options...
Surya Posted September 12, 2015 Share Posted September 12, 2015 Add to startup at local policy editor?(I dont know for sure test it) No matter whatever the challenge maybe control on the outcome its on you its always have been. MY UDF: Transpond UDF (Sent vriables to Programs) , Utter UDF (Speech Recognition) Link to comment Share on other sites More sharing options...
DigDeep Posted September 12, 2015 Author Share Posted September 12, 2015 I was adding the code in HKCU to get it Startup. I found that adding in HKCU does not allows Admin Rights. I changed the registry path to HKLM and now it is working correctly with Admin Rights and no issues.Thanks. Link to comment Share on other sites More sharing options...
jguinch Posted September 12, 2015 Share Posted September 12, 2015 (edited) For the scheduler, the scheduled task must ber configured with "Run with highest privileges" options and the credentials of an admin user. Edited September 12, 2015 by jguinch Spoiler Network configuration UDF, _DirGetSizeByExtension, _UninstallList Firefox ConfigurationArray multi-dimensions, Printer Management UDF Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now