Tagged Questions

Text file containing a sequence of commands or program invocations that does not need user intervention.

learn more… | top users | synonyms (1)

0
votes
2answers
13 views

Output redirection at the beginning of line

I'm used to specify output redirection on the end of the line like: echo blah > output.txt Both in Windows and *nix. Recently I'm seeing more and more examples that redirect at the beginning of ...
1
vote
1answer
14 views

WMIC - how to check if return empty value?

I'm making a batch file to make log of computer (I need save some informations before format PC's on my work...) So I found some commands to create this log, see: rem -- Windows Version wmic OS get ...
0
votes
1answer
13 views

Prevent ConEMU from closing tab after last program exits

What I want is some way to click on ANY batch file from Explorer and see the output without writing a helper script to PAUSE it afterwards. This is a question which seems likely to generate more OT ...
0
votes
1answer
18 views

“START /W” with additional switches

I am trying to run a silent install of several exe's via a batch file, however need them to run one by one instead of simultaneously. It seems like "START /W" wont work when switches not native to it ...
0
votes
0answers
8 views

VLC Command Line Flag --loop from Batch File Not Working

I used to have a batch file that started a playlist in VLC, set to loop indefinitely. Now though, I'm not sure if I have messed it up at some point or a new version of VLC has rendered it obsolete, ...
0
votes
1answer
20 views

Batch Move using wildcard in filename is getting files that do not match parameters:

I have a number of files with a 3 digit prefix. I'm attempting to move files based on the prefix using a wildcard. I expect that move 100*.sql subdir would only move files with the .sql extension ...
1
vote
1answer
28 views

Using msiexec to uninstall programs

I have found a batch file that removes a lot of bloatware etc. Example: start /wait MsiExec.exe /I{DB731A07-34DE-4BE0-AE94-45C83E28A56C} /quiet I guess the {DB731A07-34DE-4BE0-AE94-45C83E28A56C} ...
0
votes
0answers
14 views

Batch file can't find specified path when run from excel hyperlink

I have an excel file that has a list of IP addresses and I have linked a batch file that runs a simple ping test and outputs the results to a text log. When I run the file from the network location ...
2
votes
2answers
33 views

How to make ConEmu attach on start

I have an existing .bat file which uses the start command to launch multiple tasks, e.g.: start cmd.exe /k "echo task 1" start cmd.exe /k "echo task 2" start cmd.exe /k "echo task 3" What happens ...
0
votes
0answers
20 views

Trigger UAC for a command in a batch

If I run in a batch the command: REG ADD HKLM\Software\MyCo /v Data /t REG_BINARY /d fe340ead from a batch I get the error: ERROR: Access is denied. If I select Run as Administrator, it works. ...
1
vote
2answers
47 views

Ampersand in Windows Password

I have a password for a Perforce account which contains an ampersand (&) and when I try to use certain P4 commands, I get the following error: Perforce password (P4PASSWD) invalid or unset. I ...
0
votes
1answer
36 views

Finding Files by wildcard name and copy them

I've got a program that compiles itself and generated .exe files in its subdirectories (such as release_win_* directories for every application "App1", "App2", etc.). I'd like to find specific these ...
0
votes
3answers
40 views

Rename files sequentially from input using batch file?

The company I work for processes bills, and I regularly have to check these bills for accuracy by comparing what was entered into the database vs. the actual bill image. Any time I find an error in ...
0
votes
0answers
18 views

Change default keyboard layout with bash script

I would like to know if there's way to create a bat script which does the following things: Add US-Dvorak as a keyboard on the computer if it's not already there. (Maybe this helps, but we also need ...
0
votes
0answers
23 views

Batch File:List all files of a type, rename files, flatten the directory

I am looking for help with a batch file(s) that will allow me to move all files of a particular type (*.PDF's for example) to a new folder. HOWEVER I would like to have features not readily apparent ...
2
votes
1answer
28 views

Batch create subfolders in path with spaces

I'm trying to create a subfolder 2015 in many project folders on a shared drive. A previous post here already explained perfectly how to do this using CMD: here. This solution said: FOR /d %A IN ...
0
votes
1answer
51 views

How to properly use this code?

I'm trying to get this code to work. I want this batch file to disable the shutdown button for the current user. How would this work? Like what would I substitute in the SID:D section? Here is the ...
-1
votes
0answers
31 views

Create a batch file to constantly ping a server and run command on success or repeat if not [closed]

I need a batch file to do this: If ping 8.8.8.8 is reply then do download file from http://www.site.com/1.txt and if ping 8.8.8.8 is request time out or destination host unreachable or general ...
-1
votes
3answers
84 views

How to run a .bat file silently and automatically

How am I going to run a .bat file in silent/background? And what command should I add to run a .bat file automatically, wherein every time I'm going to turn on my PC everyday the .bat file will ...
0
votes
0answers
10 views

How to switch user rights within Batch file (de-elevation after elevation and back)?

I have a batch file that I need to run as Administrator, but within this batch file I need to run some commands as non-administrator, followed again by admin-commands. admin commands user commands ...
0
votes
1answer
29 views

net use maps to wrong user on Windows

I have a Batch script that I need to run with elevated rights (starting Services etc.). This script also does net use g: \\network\path. But because I run the batch file as Administrator the mapped ...
-1
votes
1answer
36 views

How to accept user input command in batch file?

I would like to write a batch file in which the user input would be run as a command, essentially functioning like command prompt. Example: batch file is run: user input: echo hello program output: ...
0
votes
0answers
31 views

RAR/ZIP Extract and Delete in Right Click Menu

In WinRAR, is there a way to use something like 'Extract And Delete Zip File' in context menu? I just need this option, it can be whether a batch file or another program that has this in context menu ...
0
votes
1answer
42 views

Find highest possible screen resolution from command line

With Powershell, I can request the current screen resolution. this is not what I'm trying to do. I'm trying to find the maximum resolution I can set the screen to (slider all up). Is this even ...
1
vote
2answers
30 views

bat file to open up a chrome browser window with no toolbars

How to use a bat file to open up a chrome browser window with no toolbars.(just like a popup window) @echo off start "Chrome" chrome --new-window http://localhost/jayambe/ this code when run opens ...
0
votes
0answers
19 views

Batch File to Send Zip File to CD/DVD drive [duplicate]

I have written a batch file which creates a Zip from a set of files. This works fine. I would now like to extend this batch file so the outputted zip file (from the above batch file) is written to a ...
-1
votes
1answer
31 views

Batch file timer [closed]

I would like to know I there is any way to make a timer in a batch file where you press something and it does something and if you don't it does something else Thanks
0
votes
0answers
21 views

Losing credentials when adding echo off

I needed to map a drive to another domain and it worked perfectly, here is the batch file. net use W: \\com-p55.test.ad.testdom.com\software$ /USER:domain\username password /PERSISTENT:YES The ...
0
votes
1answer
38 views

How to delete loopback adaptor in Windows 7 using batch script?

I have created 10 loopback adaptors on Windows 7 using devcon devcon -r install %WINDIR%\Inf\Netloop.inf *MSLOOP I put this in for loop and every thing is ok but now I want to delete them using ...
2
votes
1answer
44 views

Reg.exe Offline registry edit

Ok I want to edit an offline registry entry from WinPE, if I am booted into the OS (32bit) the reg key is: hklm\system\currentcontrolset\services\mountmgr\noautomount So I boot into WinPE and run ...
1
vote
1answer
34 views

How to have a batch call another batch based on its location?

I have made a file I will put up for download. It involves one batch file calling another. Most of the time this is not a problem, but in my case I have no clue where they will download it. So how ...
0
votes
1answer
36 views

How to unhide a batch file

I am trying to make a .bat script that will unhide another .bat file in the same folder only once. I am making an auto backup for a game, but first I want the user to agree to Terms of Use and ...
5
votes
1answer
60 views

Why do my .BAT files on Windows 7 not PAUSE properly?

I've been playing around with writing batch files on my computer for some time, and I am confused about why PAUSE doesn't work like I thought(maybe I'm just doing it wrong idk, just really confused). ...
-1
votes
2answers
68 views

creating a batch file to run different codes sequentially

Im trying to create a .bat file with with different codes, each of these codes exceute different commands, but I don't want to run them separately but in one batch file. All my batch codes that ...
0
votes
1answer
49 views

Batch is starting too fast after reboot

So i have batch1 as this REG ADD HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\RunOnce /V 2 /D "%~d0\bat\batch2.bat /f and then I reboot the computer (Windows 8) and batch2 starts. It seems like ...
1
vote
0answers
28 views

How to save Ping record in every single hour for 2 weeks?

how do I save the record ping "in every single hour" for a certain period, for example for 2 weeks, with the format dd / mm / ss, dd / MM / YYYY and beside it is the result of the ping. So we can ...
0
votes
2answers
49 views

How to you tie different batch commands into one file to run sequentially

I have a 5 batch files but I want to put them all in one file to run one after the other consecutively. Is that possible? What is the command that can tie the different files together .. I don't want ...
0
votes
0answers
40 views

How do I create a batch file to insert text from a .txt to a new txt and repeat the task?

wow, bad title, but here is what I am looking to do. Text-file-1 contains: 123.com 234.com 567.com I need to have those values inserted into a new document in 2 places, and them move to the next ...
2
votes
1answer
91 views

Batch delete temporary Windows files (system, browsers, cache, etc) for all users

Is anyone in this community using a particular technique to achieve batch deletion of temporary data (such as Windows temp folders, browsers cache, etc) for all users? The tricky part seems to be: ...
0
votes
2answers
42 views

send output of batch file to current directory

I have a .bat script that concats some text files into one big file. I would like to have the resulting file go to the current directory instead of the hardcoded path. Here is my script: @echo off ...
1
vote
2answers
96 views

How can I zero-pad numbers in a Batch FOR loop?

I am writing a batch file to do some operations on remote computers in my building. They are all named with the same prefix, but the number at the end changes (01–65). I tried to follow an online ...
1
vote
0answers
49 views

Unable to send files over 1 MB via FTP on Windows

I tried to send multiple files via FTP commands using simple batch script. It works fine when the file size is less than 1 MB but when the file is larger than 1 MB I get the following error log. ...
0
votes
0answers
15 views

Automate the closure/reopening of browser windows

Aim:- To have an internet browser logged in to a live stream and automatically close at a set time, then reopen a new browser window to a different URL also logged in to a live stream. These windows ...
-1
votes
0answers
46 views

Batch file to delete as much as possible, before shutting down?

I'm in the process of deploying a product for manufacturing. During manufacturing my machines will have a WinXP image installed (using FOG Server) that includes many of our debugging tools, things ...
0
votes
0answers
24 views

Batch ren Command - Only Rename Files with This Pattern

There's a program I use that renames some files to a random string on each use. It's annoying, and I can't get it fixed, so I wrote a script to change them back when I'm done using the program. The ...
0
votes
2answers
48 views

Batch file, script or shortcut to delete the most recent file in a specified folder

anyone know how to make a batch file or script or some other simple thing like a shortcut that calls some exe to do the following: I want to click on something (batch file, script or shortcut) that ...
0
votes
0answers
31 views

Windows 7 adding context menu entry

I followed this tutorial which explains how to lock an unlocked bitLocker drive without restarting explorer. This works perfectly. However, when I click "Lock Drive" in the context menu I get: ...
1
vote
1answer
96 views

Batch file to combine pdf files in alphabetical order

I want to create a batch file to combine selected pdf files in alphabetical order. Currently I have the following script: @echo off setlocal enabledelayedexpansion FOR %%A IN (%*) DO (set ...
1
vote
1answer
38 views

Windows batch equivalent of bash's set -e

Is there a Windows batch equivalent to bash's set -e, which causes the shell to exit immediately if a command fails with nonzero exit status (except in places where it's expected like in an if ...
2
votes
1answer
37 views

How to project all the files or newest files that were added to the directory using gdalwarp and commandline(.bat file)

How am I going to automatically detect all the files that were added to the directory and then project it immediately?Because everyday I am downloading hdf files and then project it from time to time ...