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

learn more… | top users | synonyms (1)

1
vote
1answer
14 views

Special characters in batch

I'm using windows 7, and I'd like to create menus, progress bars, etc. with special characters like this. How to do this?
0
votes
1answer
22 views

Add item to “New” context menu in Windows 8 for only one user without admin rights

I am trying to edit the registry on my windows 8 computer so that I can create a batch(.bat) file from the "new" menu. The only problem is I don't have admin rights. So I was doing some research and ...
0
votes
2answers
35 views

How to call perl file every minute from batch file

I have written a perl script which i try to call every 1 minute from a batch file. There is no error but it do not call it every 1 minute. It just pop command prompt when clicked once on .bat file. ...
1
vote
1answer
7k views

Run a batch file on a remote computer as administrator

I am trying to run a batch file (to install some software) on a remote computer. To do this, I am using PSExec. psexec.exe \\COMPUTER C:\swsetup\install.bat This works fine, apart from some of ...
0
votes
1answer
23 views

Can Windows XP use net send command to send a message to a later version of windows?

The net send command can only be used in Windows XP or earliar versions. But can a Windows XP computer send a message to a later version of windows using the net send command?
34
votes
3answers
33k views

How does the Windows RENAME command interpret wildcards?

How does the Windows RENAME (REN) command interpret wildcards? The built in HELP facility is of no help - it doesn't address wildcards at all. The Microsoft technet XP online help isn't much better. ...
1
vote
2answers
11 views

Mac Terminal File Rename Randomly

What is the best way to rename files for example .JPG & .jpg at the same time. I have looked on here and google and come across things like below but is there a way to cover both? Script: for i ...
2
votes
2answers
55 views

find a directory and opening it in Windows with cmd

is there possibly any way to find the directory of a file ("example.txt") and then if it finds the file open the directory (such as "c:\example\sub\") on cmd (or vb)? of course looking in all the ...
0
votes
0answers
26 views

appending folder name to filenames

please help me with this: for a file structure in a parent folder (say "C:\Folder 1") that contains: Folder A\File a.txt Folder B\File b.txt I would like to prefix the folder name to the ...
2
votes
3answers
34 views

Windows 8.1: Restore .bat file association to default

A few weeks ago I accidentally changed .bat files to open with Notepad++ (a fairly common issue I believe). On Win XP and Win 7 I had a .reg file that updated the relevant registry keys and sorted out ...
0
votes
2answers
3k views

/ was unexpected at this time

I am getting "/ was unexpected at this time." while using the below for loop for some cases only. for /f "tokens=1,* delims=;" %%m in (file.txt) do ( echo Inside Loop echo %%m ) I'm ...
0
votes
0answers
22 views

Run all .bat files contained in several subdirectories recursively in Python? [migrated]

I want to run x.bat automatically and recursively in Python: C:\test | +---folder1 | x.bat | +---folder2 | x.bat | . .----folder..n x.bat To get started I have ...
0
votes
1answer
21 views

Make Batch file to add special tags at the front of video files at one folder

I always make download for learning tutorials videos , Some times I don't remember where I can find those videos because they are too many , so I decide to make tags to those file and put them in ...
2
votes
3answers
2k views

In Windows XP, how may I change the default browser from chrome to IE on the command line, without admin privs?

Situation: 1. Need to Set the default browser to IE via cmd(problem) 2. Need to do a Citrix login via IE(amounts to loading a url) because it wont run in Google Chrome 3. then set default ...
0
votes
2answers
40 views

Why does “cmd /k” reset/clear/delete command history?

Can anyone explain why cmd /k clears the command history of my window terminal (CMD). When I run a batch file within a previously CMD and I put cmd /k at the end of the line, the command history will ...
-1
votes
0answers
18 views

batch: difference between array and list + reading list item [closed]

what is the difference between a list and a array. I tried to read a single item from a list but it seems it is only possible if I work with arrays. So what is difference since the declaration is ...
0
votes
0answers
28 views

Make a batch file close when a program different from the one it starts closes

I need to make a batch file that starts one program, and closes when another closes, but i cant get the batch file to work without starting two instances of name2. When I only use Start /wait, the ...
1
vote
2answers
23 views

Why is the value of ErrorLevel not updating?

I am trying to write a subroutine in batch to determine if a computer has Deep freeze installed or is safely unfrozen. (For those who don't know, Deep Freeze is a program that is commonly used to ...
3
votes
2answers
2k views

How to run a windows .bat script with wine from command line?

I'm trying to run a batch script from my mac terminal using wine (in order to provide arguments to a windows executable and piping output). so far I've tried executing wine runme.bat but ...
0
votes
1answer
41 views

how to get files list in a folder with batch file without file extensions

What I used is below and its perfect but results are with file extension.(ABC123.pdf) dir /a /b /-p/o:gen >C:\WINDOWS\Temp\file_list start notepad C:\WINDOWS\Temp\file_list I need results ...
1
vote
1answer
23 views

Batch file to move files created daily to a specific month folder

Files get placed in a directory daily: myfile11515, myfile1243, myfileABC Need to move them to a different directory on the same computer that has the month folders: January February March etc. I ...
1
vote
2answers
4k views

How to send mail from a Windows batch file

I want to send a mail from a Windows batch file. Here is my code: blat test.log -server smtp.gmx.com -to dest@gmail.com -f address@gmail.com -s "test mail" -u "address@gmail.com" -pw "password" ...
0
votes
2answers
14 views

Batch File not working after modification

I have a batch file that creates folders in other client folders. I added one additional folder to be made now the bat file won't work. Am I missing something here? @echo off set Dir=y:\(Directory ...
1
vote
1answer
31 views

Oracle SQL Plus expdp in bat file

I try to export all my bases with a .bat file, but when the .bat file open and connect in sqlplus, the program don't read the last of file. I need export and log all export with Spool. The .bat is ...
7
votes
5answers
16k views

Is it possible to automatically run a batch file as administrator

I am wondering whether it is possible to automatically open a batch file as admin when you double click on the batch file, because the commands need to be run with administrative rights. Note: I ...
0
votes
1answer
45 views

How to stop a running .bat file which runs after every 10 minutes

I have written a .bat file which runs every 10 minute. The problem is now when i want to stop it it never stops. (This .bat file further calls a perl file in the code). What can be done to kill it ? ...
1
vote
1answer
43 views

Running a batch file command with arguments

I'm creating a script to do some repetitious OpenSSL work, but cannot seem to get the batch file to execute the commands. Once the file has navigated to the correct directory, I try running: openssl ...
2
votes
3answers
3k views

How to set to a variable, the result of a expression

I need to extract the date of a file, for then use this string as part of the name of a new file. I trying to solve this using the next commands: First I get the details of the file and redirect the ...
51
votes
9answers
120k views

How to run a batch file without launching a “command window”?

On Windows XP, can I run a batch (.bat or .cmd) file, via a shortcut, without a "black window"?
2
votes
2answers
3k views

Setting multiple environment variables in a shell spawned via windows batch script

I have a batch file that spawns a shell with a modified path with the following command: cmd /K set PATH=%PATH%;<additional path locations> I want to set additional environment variables for ...
1
vote
2answers
3k views

Looking to create a batch file capable of editing a line (or word) in a text file

I have a text file (...\config.txt) containing 2 lines which looks like: Preamp: -4 dB Include: surround.txt I need to change "surround" to "headphones" in that config file. I really need to make 2 ...
0
votes
4answers
2k views

Minimize a program's windows after running it via .bat/.cmd

I'm trying to find a way to auto-minimize a program just after running it from a .bat file. I'm launching a SSH session via putty, and I'd like putty to auto-minimize. I use it just for the SSH ...
3
votes
1answer
3k views

Install a Teamviewer host silently with custom password

Our company has the custom Teamviewer hosts that we can run silently with the /S switch. The issue is that we can't connect due to it not setting a password that we know. Does anyone have any thoughts ...
0
votes
4answers
3k views

Run Windows batch files at startup or when any user logs on

I have a server access where I want some batch files to run automatically for any user at startup. The problem is: Other users are unable to run this file and it is required to be run as the user ...
0
votes
3answers
3k views

run 'net user' command as administrator

I was writing a simple batch file with the following command net user Abhi * where Abhi is my username and I am the administrator of my computer. On execution, it prompts for a password and then ...
0
votes
1answer
50 views

how to download pictures with wget

i would like to download pictures from http://myhomepage.com/plots/20150111-03/4711/4712.png every 3 hours. "20150111-03" is variable, rest is stable. That means every 3 hours the download looks like: ...
1
vote
2answers
2k views

How to input YES in a batch file automatically?

I am uninstalling Citrix client using a batch file. The batch initiates the uninstall successfuly, but I need to input YES (for confirmation) automatically. How can I do this in the batch file?
0
votes
2answers
43 views

My “break” command is broken

I am not a programmer and I am hoping you can help me. I am using Windows 7. I have a .BAT file which was running fine up until yesterday, specifically what if failing is the "break" command I use ...
0
votes
1answer
38 views

Batch file for getting all file names within a folder

I'm using a program called Irfanview which can merge two images into one using its command line function. Here's an example: i_view32.exe /panorama=(1,C:\folder1\img1.png,C:\folder2\static_img.png) ...
1
vote
1answer
2k views

Batch file for changing IP address not working in Windows 8

I have used batch files for years on XP and Windows 7 to change the IP settings on my Local Area Connection. For example: netsh interface ip set address name = "Local Area Connection" source = static ...
0
votes
2answers
385 views

Copying files that match one pattern but not another

I have a number of files that follow a pattern like this: <BaseName> . <Version> [ - <Tag> - <#> ] . <Extension> For example: basename.1.0.0.ext ...
0
votes
2answers
2k views

Cut a part from a filename (windows batch)

I got files named like this: cam1(word1 word2 wordN) (24-04-2012 00-11-13).mpg cam2(word1 word2 wordN) (24-04-2012 00-11-13).mpg cam3(word1 word2 wordN) (24-04-2012 00-11-13).mpg Need to cut (word1 ...
1
vote
1answer
3k views

Batch file to install TotalCommander without User intervention

I am new to windows batch file. Here is my first attempt in batch file. Here is my requirement: I should have batch file. When executes, it should read the XML config file for the software list to be ...
4
votes
2answers
278 views

The Directory name is too long in batch

I already asked the question in stack overflow, but did not get any answer from anyone. So i am asking the same question here also. I am trying make a program which will calculate size of all folder ...
1
vote
2answers
35 views

Is there a more compact way to use the IF loop functioning in a batch file?

The classical way is if "%name%"=="john" goto ok if "%name%"=="eric" goto ok if "%name%"=="mary" goto ok But can this be done in more compact way?
1
vote
2answers
60 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} ...
1
vote
1answer
56 views

Need Batch File to close a Window.. NOT the batch window

Complete novice here so please forgive if the answer is obvious. I have a batch file that does the following. Starts program 1 Waits 3 seconds (I have to click a button on program 1 after it opens) ...
0
votes
1answer
23 views

Associating Windows file extension with specific bat file and support argument passing

On my Windows 7 system, I have associated the .blend extension with a specific bat file I wrote, which is shown below: blender.bat: set PYTHONPATH="" "C:\Program Files\Blender ...
9
votes
2answers
18k views

How can I perform a ping every X minutes and check the response time?

I am currently working in a big company and we have serious latency issues. This is happening in a process control system, and is unacceptable (Open a valve sometimes take 2 minutes before command ...
0
votes
2answers
40 views

How can I remove all but last 10 characters in a group of files

How can I rename a group of files like admin_ball_126608454.gma another_thing_384157357.gma to ds_126608454.gma ds_384157357.gma