Scripts Thread, Elevated Command Prompt in Coding and Web Development; I am trying to run a .bat file that clears a log file on a windows 8 laptop each time ...
30th October 2013, 04:38 PM #1
- Rep Power
Elevated Command Prompt
I am trying to run a .bat file that clears a log file on a windows 8 laptop each time the user logs on if I have UAC turned off it works fine but then the apps on the Metro screen don' work, but if UAC is turned back on then it wont run due to it not being an elevated cmd prompt.
Is there a command line I can put at the start of the .bat file which will elevate the prompt so the remainder of the file can run ???
30th October 2013, 05:03 PM #2
Can you not run the batch file as a scheduled task that is triggered at each logon on the laptop, that way you could have it run as an administrator or system and not need to sacrifice security.
30th October 2013, 06:21 PM #3
If a domain laptop use gpp to remove the file.
29th November 2013, 10:06 AM #4
- Rep Power
Try running this as a scheduled task run with the highest privilege. I believe this should still work on Windows 8 as it does with Windows 7.
By Garacesh in forum Scripts
Last Post: 13th February 2013, 04:41 PM
By sebbywebby in forum Windows 7
Last Post: 6th December 2010, 03:32 PM
By russdev in forum Windows
Last Post: 21st April 2009, 08:39 AM
By BatchFile in forum Virtual Learning Platforms
Last Post: 27th January 2009, 12:13 PM
By DaveP in forum How do you do....it?
Last Post: 21st March 2007, 12:37 PM
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)