How to Modify Task Planning Programs through Batch Processing Files?

Min Wang 0 Reputation points
2023-06-30T03:19:29.1033333+00:00

As shown in the figure, in the "Task Planner Library ->Microsoft ->Windows ->Windows Update", set "Scheduled Start" to "Disabled". Can I quickly execute it by editing the reg file or bat file

图片

Windows for business Windows Client for IT Pros User experience Other
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Limitless Technology 44,746 Reputation points
    2023-06-30T14:24:47.47+00:00

    Hello there,

    To modify task scheduling programs using batch processing files (batch files), you can utilize the Windows Task Scheduler command-line tool, schtasks.exe. Here's an outline of the steps involved:

    Open a text editor (such as Notepad) and create a new file.

    Start the batch file with the @echo off command to suppress command echoing.

    Use the schtasks command with appropriate parameters to modify the task scheduling program. For example, to modify an existing task named "MyTask":

    schtasks /Change /TN "MyTask" /parameter value

    Replace /parameter value with the specific parameters and their new values that you want to modify for the task. Refer to the schtasks documentation or use schtasks /? to see the available parameters.

    Repeat Step 3 for each task modification you need to make.

    Save the batch file with a .bat extension (e.g., modify_tasks.bat).

    Double-click the batch file to execute it, or run it from the command prompt.

    When the batch file runs, it will execute the schtasks commands to modify the task scheduling programs as specified. Make sure to run the batch file with administrative privileges if you're modifying tasks that require administrative rights.

    I used AI provided by ChatGPT to formulate part of this response. I have verified that the information is accurate before sharing it with you.

    Hope this resolves your Query !!

    --If the reply is helpful, please Upvote and Accept it as an answer–


  2. Min Wang 0 Reputation points
    2023-07-04T06:31:55.1066667+00:00

    Run the file in administrator mode,No effect:

    @echo off

    schtasks /Change /TN "ScheduledStart" /disabled

    EXIT

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.