I have written a script that has to be run, before the explorer shell is loaded. So to do this i have written in teh batch routine to write a registry engtry to the ‘runonce’ key, to load the batch.
All our machines reboot nightly, but this key isn’t being actioned. The entry for the batch still exists in the registry, its like windows has been obmitted from actioning this key.
Does anyone have any ideas where to look to see what is stopping this key to run? Also the user account that automatically logs on is part of the administrator group, so i dont think it can be permissions.
I don’t think that matters if i am reading your post right
The runonce only should run as long as it has admin rights
your post above hinted that the machines setup to auto login and is a member of the admin group therefore it should pick up the batchfile and run.
If scenarios is different and your talking admin while your tinkering but the runonce is expected to run for a non admin user, then it will not execute for std user.
Well the user account that auto logon is part of the admin group. But the applciation that deploys the registry entry ins’t.
It does write to the registry with no issues, for i can check it and see its done the correct thing.
On my pachine and on test machine, it works everytime, its jsut in a live environment it fails todo so.
RunOnce deletes the key data when executed anyway unless you add some prefix which then make it deleted after its executed.
Don’t ask me what the prefix is * or a ! you’d need to look it up on m$
If your intention is for this bat file to run everytime a machine starts then it should be put under Run - but if its a one time never to be executed again unless placed into an update then yes RunOnce is best place for it.
Your at the limit of my knowledge so if a new key don’t work I am uncertain what to suggest.