Discussion Locked

Batch file Beep

0 helpful
7 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.
I would like to know the command or syntax for a beep command. I am writing a batch file that deletes selected files and then copys selected files and I want to be able to have the computer beep a couple of times between operations.

7 replies

by westdodge

The problem is getting the [CTRL]G character into your batch file. The following will create a batch file with the correct character that you may then copy and paste into another batch file.
At a DOS prompt, type:
ECHO @ECHO OFF > beep.bat [ENTER]
ECHO ECHO Ctrl+G >> beep.bat [ENTER]
All you will see is a dot or block when you look at the [CTRL]G character in a text editor, but you can copy and paste that line into your other batch file.

by westdodge

You may also try this:
Load your batch file in DOS EDIT:

When the cursor is in position, press [Ctrl-P] then immediately after that press [Ctrl-G]. You should now see a dot where the [Ctrl-G needs to be.

Both solutions seem to work just fine.

This discussion is closed to new replies.