# Windows – the command line to schedule a task to be executed once and soon

I know there is the at and schtasks.
But I couldn't figure out how to use them to execute a task soon and once.
I have read about a soon command, but there isn't such command in my Windows version.

I plan to include this command in a batch file and, because of that, I can't hardcode the start time.

Starts a scheduled task immediately. The run operation ignores the schedule, but uses the program file location, user account, and password that are saved in the task to run the task immediately.

Syntax:

schtasks /run /tn TaskName [/s computer [/u [domain\]user /p password]] /?


So just define the task, then run it immediately at any time you need to.