Most voted "batch" questions
"Batch", also called "batch processing", refers to the(s) execution(s) of one or more commands, which may be internal, and/or external. As, also, can(m) contain (in) program(s) call(s), on a computer, for various executions, with or without user interaction, to meet the desired processing.
Learn more…222 questions
Sort by count of
-
1
votes3
answers1106
viewsDoubts with conditional commands in Batch files
The Intent is to copy files .jpg to a subfolder called \image, and the others, I mean, different files from .jpg, to the folder \New folder (2)\. Only it’s not working, which could be wrong? Below…
-
1
votes2
answers19198
viewsScript /.bat to kill certain process on all users logged in to the computer
Well, folks, my problem is this: I have a process called gdc.exe. If a user has this process open and another user logs into the machine and tries to run the program that generates this same…
-
1
votes1
answer306
viewsWscript http post/get in Jscript for PHP
I’m in the mood to make a Jscript script to run by Wscript(native Windows command processor)... And I have a question: How do I send data in POST or GET (as in a form) to a PHP page? From now on,…
-
1
votes1
answer91
viewsBatch Move and Del commands are not working
@echo OFF mkdir saida sort %1 > cadperfiSorted 2>> saida\error.txt start MAKEOPEACER5.jar cadperfiSorted del cadperfiSorted //OPEACER5 é um arquivo gerado pelo .jar move OPEACER5 saida This…
-
1
votes2
answers536
viewshide the batch input through this file
I am trying to encrypt a folder hiding it, but when entering this code, it forwards me to batch to ask for the password, when I am entering it shows the password and does not hide it. cls @ECHO OFF…
-
1
votes1
answer839
viewsHow to set a time to automatically shut down your computer with a Batch file
I am following a tutorial from the site Super User of the network of Stack Exchange sites, with the idea of programming my computer to shut down by passing X time, after we have run or double click…
-
1
votes1
answer686
viewsBatch to locate a subfolder, move all files to a level above and delete the folder
I have this structure: .. ..\FolderA\FolderX\File1.txt ..\FolderB\FolderX\File2.txt ..\FolderC\FolderD\FolderE\FolderX\File3.txt I need a batch to locate all "Folderx" folders in the subdirectories…
-
1
votes1
answer164
viewsScript that erases files by Spellnumber
I wanted to delete several types of extensions, but I don’t know how to increment if in batch, someone could help me and teach me how to increment if in the code below: @echo off cd…
-
1
votes1
answer6742
viewsEnter user and password in bat file
I have a. bat file that automatically copies files from one server to another. We are updating the environment and this server will be modified and when testing . bat I received the following error:…
-
1
votes1
answer3356
viewsEdit txt file by bat
I have the following problem: In a Windows directory, I have 3 files .txt that every day is created automatically. Within them there are several lines with information. I wish to erase two lines…
-
1
votes0
answers726
viewsAutomate IE configuration process for NF-e issuance
To send nf-e within my system I need some parameters of Internet Explorer to be properly configured as follows: • Mark SSL options • Uncheck TLS options • Uncheck Check server certificate…
-
1
votes1
answer88
viewsMake the user enter information
I’d like to know how do I make that on the screen of script in Batch appear: "Please enter your name" Thank you, any help is welcome
-
1
votes2
answers183
viewsBatch file anchored
How do I get a batch anchored to a folder for a backup operation on a USB stick where the drive letter always changes example: @echo off mkdir ..\subs move /y .\*.srt ..\subs pause exit…
-
1
votes2
answers3516
viewsHow to generate random numbers at command prompt?
I have a file on .cmd and I need it to generate random numbers with 10 algorithms. Like for example 9006100001 and 1579970319 randomly generated. I currently have the following function generating…
-
1
votes2
answers2019
viewsInvalid character in file . bat
Sirs ! I have a . bat file that I use to start Apache Tomcat from my application in debug mode. But while running this file on CMD, the first thing displayed is the following message: '' is not…
-
1
votes2
answers632
viewsAssign directory of a searched file to a CMD variable
In batch I can search a file with the following command: C:\>DIR /S /B PROGRAMA.EXE And if the file is found it will return like this: C: Users Dev Desktop Program.exe I would like to be able to…
-
1
votes2
answers695
viewsHow to give the option for the user to choose the destination folder in BATCH?
I do not want to enter the destination manually, for example: set /p destino=Escolha o local de destino: robocopy /s /e pasta %destino% RESOLVED: Using cmd (set & for) + Powershell (new-Object…
-
1
votes2
answers1583
viewsHow to close a. bat file with another . bat file
I have a.bat file running this code: cd C:\Users\PC\Desktop\nginx-1.10.2\php php-cgi -b 127.0.0.1:9000 But it needs to be open while it’s being used. Is there any way to create another . bat to…
-
1
votes1
answer228
viewsCheck mapped network unit size
I’m developing an app, and I need to check the free space on the mapped network drive, I can grab the contents of a file in my application directory, so I created a script to execute the command to…
-
1
votes3
answers16842
viewsWhat is Batch and Online Processing?
Batch I researched and saw that this is a batch processing.... Ta, but what does it mean ? and what would a batch file ? (refers only to the .bat ?) and what would batch drives ? What’s the…
-
1
votes1
answer1285
viewsAdd suffix to first line text file using BAT
Good staff! I’m editing some F1C game mods, which uses text files to store pilots' AI data. In the first line of each file come the name of the pilot: Michael Schumacher ... and I’d like to add a…
-
1
votes2
answers6493
viewsWait for BAT command to run to continue
I need to run a bat file with the following content: ECHO "Mensagem 1" copy xxx yyy ECHO "Mensagem 2" outro.bat param1 ECHO "Mensagem 3" copy zzz ooo However when it runs the other.bat my script…
-
1
votes1
answer6078
viewsHow to change (replace) the information from within a . txt file using . bat?
What I want to do is kind of a sed in shell. I have a file .txt as various information inside, I want to replace one sequence of numbers by another. How far I’ve done the script identifies the files…
batchasked 7 years, 5 months ago Maressa Corrêa 11 -
1
votes1
answer5038
viewsCheck file date and time and keep the most current in Batch
I need a program in Batch where I will specify two files, it will compare the date and time of their creation and if the first is more current it would delete the second and copy the first,…
-
1
votes1
answer3765
viewsSearching and Separating Files Using . bat
I have a daily/monthly process where, I have a . txt that has a list of about 10,000 file Ids (one ID per line) (exemplo_content_file . txt) { 12345 23456 34567 45678 56789 } Each file ID (ex:…
-
1
votes2
answers294
viewsBoost Performance Bat
Currently I have a . bat that runs copying files from the network from one server to another. This made a job that was done manually much easier, but I noticed that by removing some increments…
-
1
votes1
answer327
viewsBatch create operating system (.bat)
It is possible to create a real operating system in batch (.bat)? Because I saw some Youtube videos where the title was something "OS in batch" (English).
-
1
votes3
answers861
viewsSimulate "ok" via command line
I have a Windows prompt command that disables proxy settings: REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Internet Settings\" /v ProxyEnable /t REG_DWORD /d 0 /f My system browsers are…
-
1
votes1
answer8796
viewsHow to create "drawings" in Batch written files
My question is this:: How do I add "drawings" to my code . bat like the ones that appear on the Linux terminal? I tried to insert the "drawing" using the Figlet Generator tool. But when I run the…
-
1
votes1
answer558
viewsClear only one row of a batch file
My question is whether there is any way to delete only one line of several. For example: the command prints three numbers on the screen of the prompt: echo 1 echo 2 echo 3 And then, he just erases…
-
1
votes1
answer4001
viewsconcatenate several txt files with line break in BAT
Can anyone tell me if to add line break, for each content of each file? For example, in a file has content (dog) and in other files other types of content, but the files have no line break at the…
-
1
votes1
answer1234
viewsCalculate two times in a batch variable
Is it possible to calculate the difference between two times with the batch and use the answer as a variable within the command? The "time" command allows you to make the calculations between start…
-
1
votes1
answer95
viewsDelete an executable file ( .exe ) after finishing without knowing its location?
The bat file has been converted to executable. The command del "%~f0" does not work! You will need to finish running the executable first taskkill /f "nome_do_executável.exe" and only then eliminate…
-
1
votes1
answer113
viewsIdentify which partition is running the script from
In the case of prompt command we can use Windows environment variables to advance paths, such as: echo %homedrive% Which will result in the attribute letter where the sistema operacional was…
-
1
votes1
answer302
viewsSave current date -X days in a variable
I have a folder that every day thousands of log files are saved and when you need to search a file by date and time is a sacrifice. I have to do a routine to save the current files in a folder named…
-
1
votes2
answers931
viewsRename the process
I have a script made in Windows CMD and wanted to see if it is possible to change the name of the process when it runs. Example: I have 3 script (1-ler_log.bat; 2 - recicle.bat; 3 - Alarm_alter.bat)…
-
1
votes2
answers128
viewsbatch files - find current file directory
I have a batch file that makes cmd point to another directory. But at a certain point, I need it to go back to the batch file directory itself. It is possible to do this?
-
1
votes1
answer267
viewspass external parameters to sqlcmd via batch
I used in the oracle so, I wonder if you have any similar method for the sqlserver (sqlcmd). Batch sqlplus.exe system/123@localhost/xe @..\CRIA_TABELAS.sql "%last_bill%" file . sql SELECT * FROM…
-
1
votes1
answer53
viewsInsert variable in script
I have the following script working normally @echo off if %time:~0,8% LEQ 11:59:59 goto manha if %time:~0,8% LEQ 17:59:59 goto tarde if %time:~0,8% LEQ 23:59:59 goto noite :manha echo "BOM DIA"…
-
1
votes1
answer513
viewsHow to set path . bat
Well my problem is the following I want to run a file. bat it goes: create a folder locally copy images from my server to the created folder hide the created folder But he ends up displaying this…
-
1
votes2
answers535
viewsStore diverse information in a batch notepad
Good morning, first I’ll put it in context. Basically I’m making an "interactive story", where basically, during the progress of history I’ll have 3 variables. I could save these variables with the…
-
1
votes2
answers597
viewsHow to enter data at runtime?
I would like to write while running a bat file. I have to enter user and password after executing a command. When executing the command I have the following output : Você foi direcionado com…
-
1
votes1
answer88
viewsHow to rename multiple . mp3 files by replacing the first argument of each one’s name with a sequential order of numbers
Imagine we had these files in a folder: 2 arquivoABC.mp3 1 arquivoCBA.mp3 3 arquivoBAC.mp3 0 arquivoBCA.mp3 So how could we make the names stay that way: 1 arquivoABC.mp3 2 arquivoCBA.mp3 3…
-
1
votes1
answer286
viewsRepeat loops with conditions seem not to work
Obs.: I believe it is error in the variables, because the loops do not work. This code stores the average execution time of backups SQL of the month and uses this time to limit the execution time of…
-
1
votes2
answers107
viewsHow to make a list comparator
I wanted to know how to make a list comparator in C# or bat, to identify only the different items between them
-
1
votes1
answer455
viewsScript to Copy Directory to Program Files folder with Administrator rights
Good afternoon, you guys, I would like to copy some files in *.vbs, to a folder in "Program Files(X86)" via logon Script. But the message that appears is that the user has no rights to make the…
-
1
votes0
answers136
viewsMonitoring Ping . BAT
Sorry, guys, I’m a total layman. I need to create a file. Bat that after inserting an IP. It monitors the ping and emits a log in case the device stops responding with date and time in a TXT file.…
-
1
votes1
answer552
viewsBatch Script to Select Files by Data
I would like to create a Batch script that scans inside a folder and its sub-folders, finding the XML files and placing them in a temporary folder. So that later, I can compress using 7-Zip. Below…
batchasked 5 years, 6 months ago Eder Silva 79 -
1
votes2
answers110
viewsProblems in batch droplet
I am beginner in batch And I’m trying to create a very simple alarm clock program. The user must set the time you want the alarm clock to ring and the program will check the time of the computer. If…
-
1
votes1
answer231
viewsPython file batch problem when activating windows task manager
I made a batch file to run a small script in python, it works normally, but when I use windows task scheduler to trigger the batch at a specific time it presents the following error: Where you say…