Windows 10: Is there a program that executes commands at certain times (in a batch file)?

Discus and support Is there a program that executes commands at certain times (in a batch file)? in Windows 10 Customization to solve the problem; Hello, everyone, I have programmed a Minecraft server and have now set the computer to go on and off to certain pages. When it is on, the start file... Discussion in 'Windows 10 Customization' started by Thiemo381, Jun 5, 2020.

  1. Thiemo381 Win User

    Is there a program that executes commands at certain times (in a batch file)?


    Hello, everyone,

    I have programmed a Minecraft server and have now set the computer to go on and off to certain pages. When it is on, the start file Per Autostart opens. But to close it I need the command /stop so the server saves. But because I want everything to be automatic, I want this to work. Is there a program for it ?

    Thanks in advance

    :)
     
    Thiemo381, Jun 5, 2020
    #1
  2. KenS5 Win User

    Batch file not executing commands

    I am trying to purge older files on a server and DFS. One batch file works while running a task and manually as admin, but the other does not. Below are examples of working an non working batch files.

    Commands execute:

    forfiles /P "C:\Foldername\MonthBackup" /D -30 /C "cmd /c echo %date% %time% @file @path @fdate && del @file" >> "\\domain\dfs\groups\Foldername\Backups\Logs\PurgedFilesLog.txt"

    Commands DON'T execute:

    forfiles /P "F:\groups\Foldername\Backups\MonthBackups" /S /D -30 /C "cmd /c echo %date% %time% @file @path @fdate && del @file" >> "\\domain\dfs\groups\Foldername\Backups\Logs\PurgedFilesLog.txt"

    I mapped the UNC to the F drive sine UNCs are not supported with forfiles or cmd.
     
    KenS5, Jun 5, 2020
    #2
  3. F.Wu Win User
    Unable to execute all commands in batch file

    Hi,

    I have a problem to execute batch file. There is an app running and monitoring UPS signal. If that signal goes true, the app will launch a batch file to close itself and then shutdown the PC after 30 seconds.

    the content of the batch file is like this:

    @Echo off

    app.exe -exit

    pause 30

    shutdown.exe /s /t 5

    However, it seems the system only executed the first two lines of commands
    app.exe, it closed the app, and did not shutdown the PC. If I run the batch file itself by double clicking the batch file, all commands are executed and PC shutdown properly.

    What is the problem and how to fix it? Thanks
     
    F.Wu, Jun 5, 2020
    #3
  4. F.Wu Win User

    Is there a program that executes commands at certain times (in a batch file)?

    Unable to execute all commands in batch file

    Hi,

    Indeed, even I deleted "pause 30", it still won't execute shutdown command. I guess the batch file is called by app itself, so when it closes itself, it also terminate the batch file thread?
     
    F.Wu, Jun 5, 2020
    #4
Thema:

Is there a program that executes commands at certain times (in a batch file)?

Loading...
  1. Is there a program that executes commands at certain times (in a batch file)? - Similar Threads - program executes commands

  2. Batch File Command???

    in Windows 10 Gaming
    Batch File Command???: I want to run a batch file that starts a backup program, but does not execute the next command until that program completes? How do I do this? https://answers.microsoft.com/en-us/windows/forum/all/batch-file-command/3af2ce6b-ace3-43cb-b6fb-5cbff8998736
  3. Batch File Command???

    in Windows 10 Software and Apps
    Batch File Command???: I want to run a batch file that starts a backup program, but does not execute the next command until that program completes? How do I do this? https://answers.microsoft.com/en-us/windows/forum/all/batch-file-command/3af2ce6b-ace3-43cb-b6fb-5cbff8998736
  4. Batch file does not wait for executed program to finish.

    in Windows 10 Gaming
    Batch file does not wait for executed program to finish.: Edition Windows 10 Pro Version 21H2 Installed on ‎8/‎3/‎2020 OS build 19044.1466 Experience Windows Feature Experience Pack 120.2212.3920.0 I have a batch file that I want to start a browser, wait for it to close, then proceed to the next instruction in the batch. The batch...
  5. Batch file does not wait for executed program to finish.

    in Windows 10 Software and Apps
    Batch file does not wait for executed program to finish.: Edition Windows 10 Pro Version 21H2 Installed on ‎8/‎3/‎2020 OS build 19044.1466 Experience Windows Feature Experience Pack 120.2212.3920.0 I have a batch file that I want to start a browser, wait for it to close, then proceed to the next instruction in the batch. The batch...
  6. Batch file does not wait for executed program to finish.

    in Windows 10 Customization
    Batch file does not wait for executed program to finish.: Edition Windows 10 Pro Version 21H2 Installed on ‎8/‎3/‎2020 OS build 19044.1466 Experience Windows Feature Experience Pack 120.2212.3920.0 I have a batch file that I want to start a browser, wait for it to close, then proceed to the next instruction in the batch. The batch...
  7. bootrec.exe not recognized as an internal or external command, operable program or batch file

    in Windows 10 Gaming
    bootrec.exe not recognized as an internal or external command, operable program or batch file: I am using Command Prompt and I type bootrec /fixmbr and it comes up with bootrec.exe is not recognized as an internal or external command, operable program or batch file. Even when I run it as an administrator. I look in the system32 folder and I can't find bootrec.exe. Is...
  8. Command Prompt/ Batch files

    in Windows 10 Ask Insider
    Command Prompt/ Batch files: [ATTACH] when i create a batch file to ping something, it spams the command and throws no response. how do i fix this? https://preview.redd.it/fyy6qwrfx7n61.png?width=256&format=png&auto=webp&s=d55552fdc7a5c297d565617f710992048238660c submitted by /u/xWasss [link]...
  9. Preventing Execution Of Certain Commands

    in AntiVirus, Firewalls and System Security
    Preventing Execution Of Certain Commands: Hello Team, Hope you are well ! I just want to know whether we can prevent certain commands in Windows Defender ATP. I want to prevent execution of below command running on Windows10: " cd C:\:$i30:$bitmap "...
  10. Batch commands

    in Windows 10 Network and Sharing
    Batch commands: I know this stuff is kind of old tech, but would anyone know how to make a script that goes through the contents of a folder or file and uses them as command-line arguments say in pseudocode it might look something like: for each item in Desktop, copy %name% to D:\ a USB...