0

I am trying to create a scheduled task that just simply runs a .bat file. But when I looked it up it up on serveral sites it said something about importing an XML file.

Is there a quick way to create a task through a batch file?

The task should be executed at xx o'clock and just simply run a batch file in a specific folder.

Anyone have some advice for me or maybe even a piece of code?

I do not want to get too advanced as I started coding batch last week

7
  • 1
    schtasks /create /?
    – Stephan
    Commented May 10, 2015 at 12:11
  • @Stephan I know, but like... I don't really know what to do from there :P
    – Albert MN.
    Commented May 10, 2015 at 13:00
  • what is the exact scenario ... do you want your users to create their own tasks ... do you want to give them a single batch file that creates 1-n scheduled tasks on their local machines ... ?
    – MikeD
    Commented May 10, 2015 at 13:09
  • At least for the 2nd case @Stephan s suggestion is a good one ... capture one or more schtasks /CREATE into a .bat file. The help flag shows you some examples, and here's a command reference ... microsoft.com/resources/documentation/windows/xp/all/proddocs/…
    – MikeD
    Commented May 10, 2015 at 13:20
  • well, we don't know your requirements. Read the helpfile, filter the options, that sound helpful to you and try to assemble them. Come back with your error messages, if you can't solve them. It's a mighty tool, but the syntax might be not very intuitive.
    – Stephan
    Commented May 10, 2015 at 15:32

1 Answer 1

1

Try this:

Start --> Run --> Type taskschd.msc --> Action --> Create a basic task or create a task

I hope this helps.

8
  • I don't think he would have this question in the first place if he was able to use the Task Manager. Commented May 10, 2015 at 12:58
  • I am able to use the task manager, and I know how to create a task :P But I want to make a "userfriendly" version where I can I just type the time/clock in a bat, and it will create a scheduled task at that specific time of day. In this case, I want to make a automatic shutdown task.
    – Albert MN.
    Commented May 10, 2015 at 13:00
  • I searched the internet, but I couldn't really another way to make a batch automatically startup, @iversen ---- But I think I have another idea!
    – Nuach
    Commented May 10, 2015 at 13:07
  • You run one batch file that after a certain amout of time it runs the other batch file, @iversen!
    – Nuach
    Commented May 11, 2015 at 12:42
  • I know I can do that :P And I am doing that so far, but I feel like a scheduled task is a better option
    – Albert MN.
    Commented May 12, 2015 at 7:23

Not the answer you're looking for? Browse other questions tagged or ask your own question.