1

GUI vs Command-Line

The task scheduler GUI provides an option to run the scheduled task in an elevated context ("Run with highest privileges"), e.g.

Scheduled Task Properties (emphasis added)

I cannot find a corresponding flag for schtasks.exe. The closest thing I can find is to export an existing task (created with the GUI) with that property set and import it (and potentially modify it later).

Is there another way to create a scheduled task in an elevated process?

mojo
  • 227
  • 1
  • 4
  • 12

1 Answers1

1

The option you are looking for is /RL:

   /RL   level        Sets the Run Level for the job. Valid values are
                      LIMITED and HIGHEST. The default is LIMITED.

The documentation doesn't indeed mention it, probably by mistake; but the command help (schtasks.exe /create /?) does.

Wasif
  • 321
  • 2
  • 8
Massimo
  • 70,200
  • 57
  • 200
  • 323