Text file containing a sequence of commands or program invocations.

learn more… | top users | synonyms (1)

-1
votes
1answer
19 views

Xcopy - Invalid number of parameters

I'm trying to create a bat file that will relocate some ECF Files from a folder to a new folder I have successfully set up a XCopy bat file for other documents (.doc, .ppt) etc and i've copied the ...
0
votes
1answer
10 views

NET USE remove if no right

I have a .bat for connecting network drives. I have 11 in total. My script works, but for now even if the user has no rights, that it connect the network drive. I would like if the user does not have ...
1
vote
1answer
22 views

Windows 7 cmd batch check installed application

This may sound like a simple question, but I'd be grateful for a quick solution: I have a batch script which runs at logon (with elevated privileges) that should run only if a specific program ...
1
vote
1answer
23 views

How can I edit local Group Policy settings using command line?

I'm attempting to throw together a script for work that allows BitLocker without a compatible TPM. The setting is "Configuration \ Administrative Templates \ Windows Components \ Bit Locker Drive ...
0
votes
1answer
11 views

pushd with rd dont work as I want

have done like this pushd \\somedrive.se\Install\Paket\XXX\ echo "start..." for /f %i in ('dir /a:d /b bu* ') do echo /q %i popd and get this output when running from a script: ...
-1
votes
0answers
26 views

Printing PDF files in alphabetical order using batch files [duplicate]

I have a folder with hundreds of small PDF files to print. How can I make a batch job to print them out in alphabetical order?
-3
votes
3answers
23 views

Batch Files make Directory within Directory

How would you create a directory inside of a directory in batch files? I've tried various times and I couldn't get it to work. Please help.
0
votes
1answer
33 views

How can I stop my browser from opening up itself and loading a page when internet is connected?

When I connect to the internet through a dongle (ISP: Tata Photon+/Tata Indicom) it opens up my default browser (google chrome) and logs on to the homepage of my ISP which is integrated by Yahoo!. I ...
0
votes
0answers
15 views

Windows Automated Installation. How can I change boot order in WinPE from a batch file?

Trying to complete automated install of windows OS. I have WinPe on a USB which is first in boot order. I have several batch files running automatically in WinPE making partitions etc. as part of the ...
3
votes
2answers
74 views

How can I make my computer do a repeated series of tasks by a script file on Windows?

When I want to update a web project of mine, I have to do the following tasks all the time: Open cmd.exe. cd into working directory of project. Run localhost command in cmd.exe (~ jekyll s). Launch ...
1
vote
2answers
28 views

Why is SET PATH= not working in the same batch file?

I have a USB flash drive with portable installs of Dropbox and emacs. One of the functions I want to run in emacs needs to have sha1sum.exe in the path, so I also put coreutils on the USB. I am ...
0
votes
1answer
50 views

Is there a way to see what an executed batch file did?

I'm pretty sure the answer to my question is a simple "No", but I'm going to try it anyways. (And a plain No would help me also.) We've got a shared computer. Folks may use it as they do, but they ...
-2
votes
1answer
58 views

How to download from a direct link using batch files and Google Chrome? [duplicate]

I want to create a batch file which is capable of downloading any files from direct links. I already tried this: chrome start ...
1
vote
1answer
71 views

A .bat file to close two services running in background

I have a Windows 7 computer with three accounts (in hierarchical order): Administrator (with password) type Administrator Guest (with a password different from that of Administrator) type ...
1
vote
1answer
49 views

How can I elevate my cmd prompt using the the cmd line

I follow this script "runas /profile /user:administrator\administrator cmd"and when it prompts me for my password it always says that it is incorrect even though i am spelling it correctly. help ...
0
votes
1answer
34 views

How do I make exclamation marks show using echo

Earlier today, I was continuing on making an RAR Password Decryptor. I was testing it out on a test RAR file with the password being just an exclamation mark but when I use my Decryptor all it says is ...
1
vote
2answers
36 views

Wildcard file extensions xcopy

I have some files that need to be copied to a directory on a schedule. All the files have the same name but the extension increments (I have no control over this, it drives me mad) I've tried ...
0
votes
1answer
40 views

Remove Icons from Desktop / Windows 7

New to the site so any advice would be helpful. I am on a computer where the network admin runs some script that continuously puts 2 icons on my desktop. I can delete them and then in a few minutes ...
2
votes
2answers
67 views

how to run bat file as administrator automatically from a non-admin account

My work account is a non-admin but I have the admin password. I need to run a .bat file as admin automatically when windows starts from my non-admin account. I couldn't figure out how to feed in the ...
1
vote
1answer
32 views

Batch file FOR command skipping lines

I need some help with the FOR command in batch filing. What I want to do is read the file "Test.txt" and read only the third line and turn it into a usable variable within this batch file. Here is ...
-2
votes
1answer
38 views

for /f %a in (Y:\el.txt) do move %a C:\Users\srinu\Desktop\test

I am run below cmds in commands prompt for Ex: for /f %a in (Y:\el.txt) do move %a C:\Users\srinu\Desktop\test after that i need result txt file Example:c:\skipped.txt (not moved File Numbers) how ...
1
vote
2answers
54 views

Batch File Pause

I was testing out a batch file and I put in pauses to double check that the script was functioning properly. My question is, if the script encounters a pause, and I alter the script, either add a ...
1
vote
2answers
41 views

Extract Specific Fields from a Multi-Lined Text File via batch-file (.BAT)

I am new to batch-program and my wife asked me to help her to speed up her load. Question is, how will I extract the business date, terminal num(00099106), transaction amount, and commission from this ...
3
votes
2answers
84 views

Command Line : Concatenate multiple files by date

I have got a plenty of .txt files in a directory. The directory also contains .png and some .pdf files. I have successfully concatenated .txt files using this command : @ECHO Off SETLOCAL for /r %%f ...
1
vote
1answer
42 views

Windows Batch to read TXT and parse lines to CSV

I've made a good deal of headway by searching this site and learning the ridiculous language that is Windows batch scripting, but frankly I'm stuck. The sample below is from our lab's old radiometer ...
1
vote
1answer
32 views

Windows Batch to read TXT and parse lines into JSON

I've made a good deal of headway by searching this site and learning the ridiculous language that is Windows batch scripting, but frankly I'm stuck. The sample below is from our lab's old radiometer ...
0
votes
3answers
29 views

Batch File to show a Directory List excluding Directories that Start with Underscore “_”

I am throwing together a batch file that will echo out a list of all of the directories in a specific path. I have a few folders in the W:/wamp/www/ directory that start with an underscore _; for ...
0
votes
1answer
35 views

How to make a timer and a loop in a batch file?

I need some help completing my .bat file. So what I wanna do is that after the program has started I wanna leave it running for like 1min then I want it to close the program and then run it agian for ...
0
votes
1answer
59 views

run multiple commands from a file after logging into putty from a bat file

I have written a bat file in which I have the following: putty.exe -t -load "ABC" -l username -pw password -m "C:\Users\pathasai\Desktop\abc.txt" In my abc.txt I have written some commands which I ...
0
votes
2answers
19 views

Suppressing error in batch command if reg

If I run the following: @ECHO OFF FOR /F "tokens=2* delims= " %%A IN ('REG QUERY "HKLM\SOFTWARE\SomeApp\Server" /v ServerName') DO SET ServerName=%%B ECHO Server: %ServerName% and the registry ...
-2
votes
1answer
36 views

I need a batch to open an file whenever the workstation is unlocked

So the batch file I need has to open an excel file whenever the password is typed to unlock the computer.I know this thing can be done with Task Scheduler but I need a batch file because this action ...
0
votes
1answer
48 views

Progress indicator in a batch file while tracert runs

I have a batch file that runs fairly quickly, BUT there are a couple tracer's that take forever to run. I want to find a way to show that something is happening (NOT showing the tracert results ...
0
votes
1answer
21 views

Run a command in all sub-folders in a batch file

I have a batchfile that looks like this: IF EXIST icon.ico ( attrib -S -H -R desktop.ini echo f | xcopy /H /Y "%~dp0desktop.ini.txt" desktop.ini attrib +S +H +A desktop.ini ) This works ...
0
votes
0answers
36 views

How to associate batch files with another application rather than default cmd?

I want to associate .bat files with another console emulator, like cmder, so that when executing them they start up with my preferred program. How to do this?
1
vote
2answers
25 views

How do I move files not accessed for a long time using a batch file?

I like to move files accessed for a long time. For instance: if I do not access some file by 7 days, it move to old sub-folder. file1.txt 1 days <keep> file2.txt 2 days ...
0
votes
1answer
20 views

Parameters with spacebars parsed incorrectly for a powershell script run from a batch file

I have a batch file that runs a powershell script and I need to pass two parameters to the script. In my batch it looks like this: powershell -executionpolicy remotesigned -File "my script.ps1" "my ...
1
vote
0answers
40 views

seach for a word in .txt files and write few line into new .txt file

Please help me to create a script to perform task as per described below. i have 2 files. A.txt and B.txt Content of A.txt as per below ITEM name TICKY title nice coffe drink type DRINK ITEM ...
0
votes
1answer
17 views

Script to access same path on different devices

Is there a way to make a batch file that access same place on a different workstation? Example path: \\station1\c$\windows\system32\spool\printers When running the script I want to be prompted which ...
0
votes
1answer
15 views

Program counting minutes from start to stop. and generates txt report.

I have created a batch file based application that installs a number of things on the machine . I would like in this context is a program that I eg can run via batch file example : "start count time " ...
0
votes
1answer
45 views

Batchfile will not exit after running (when more than one spawned)

This batchfile (any all others) will not exit after running when more than one are spawned. I am an experienced MS-DOS/Windows/Java developer and I have never seen this behavior before. Something ...
0
votes
0answers
25 views

Command works in C:\ But not in Users

I am working on a backup program before we image users computers and I want to search for certain types of files. for /r /d %a in (*) do @copy "%a\*.png" "%usr%\file\pic" < All It works great ...
0
votes
1answer
41 views

Can I launch a URL in browser, from scheduler, unless the URL is already open in a tab in the default browser

I'm using the task scheduler in Windows to launch a page in the default browser at a particular time each day. The problem I have is that if the page is already open in the browser, it will open that ...
0
votes
2answers
70 views

Find group of words in a text file and extract the line to new text file

my file ref.txt contains word "hi" "hello" "aloha" as per below: hi hello aloha And I have one more file abc.txt which contains many words including the above 3 words. Now I developed a ...
0
votes
2answers
50 views

Log date and external ip address with curl and batch (Windows)

I am having weird issues where my external IP is changed VERY often as in every 2, 3 minutes. I have a dynamic dns service in place that I update via task scheduler with curl called in a batch file. ...
0
votes
1answer
39 views

.bat that calls AFUDOS to flash BIOS

I've got a .bat file that is supposed to flash the BIOS on my laptop. It reads as follows: @AFUDOS T.105 /p /b /n /e /x /reboot Before actually running it, I would like to unterstand what it does. ...
1
vote
2answers
62 views

How can I force a scheduled .bat job to run in the foreground?

I have a simple .bat that runs a PHP script at the same time every day. @echo ON php C:\path\to\script.php argument pause It runs fine when I double-click the .bat file. And I set up a scheduled ...
0
votes
1answer
31 views

Is it possible to substring an environment variable in a windows 7 shortcut? [duplicate]

If I have an environment variable in Windows such as %username% if there any way I can substring that? I'd like to substring it down to the first 8 characters.
0
votes
2answers
64 views

WinSCP script hangs when connecting to host

I've batch script that runs winscp with script, and sometimes WinSCP hangs when is "Connecting to host". Is it possible to set timeout that WinSCP stops trying to connect and shuts it's self after x ...
-1
votes
1answer
33 views

Grab filename for manipulation

Similar to my request here I'm looking for a way to take the name of a numbered file and use it else where in a batch script. For example, in a folder there would be a file named 159 and I would ...
0
votes
3answers
52 views

Multiline && combinator operator for command chaining in batch file

I see that this operator is used in windows (and might be Linux?) to chain/combine multiple commands in one line. Commands are executed one after another, as long as preceding complete successfully ...