Search found 6 matches

by stephjo
10 Nov 2019 16:51
Forum: DOS Batch Forum
Topic: Play a sound (.wav) file, without opening an application
Replies: 4
Views: 1066

Play a sound (.wav) file, without opening an application

Hello DOS folks, I was wondering if there's a way in DOS (or Windows 7 in general) to play a media file without invoking a software. Here's what I am looking for ... at the end of a batch file or a C++ program that takes many minutes to complete, I'd like to "beep" by playing the file "C:\Windows\Me...
by stephjo
26 Oct 2019 12:44
Forum: DOS Batch Forum
Topic: Eliminating multiple empty lines
Replies: 4
Views: 4607

Eliminating multiple empty lines

Hello DOS pepole, I have a 1000 text files and would like to replace three (or more) empty lines with two empty lines. How could I do this? That is, I'd like to replace three (or more) new line characters with two new line characters. I'm sure there's an easy way in DOS than writing a c++ software. ...
by stephjo
03 Aug 2018 03:28
Forum: DOS Batch Forum
Topic: List files modified since set date
Replies: 2
Views: 791

List files modified since set date

Hello Fellow Batch File Enthusiasts, I am seeking help to write a batch file that lists only those .txt files modified on or since a given date, say 07/15/2018. Could you please help me? @echo off for /f "delims=" %%a in ('dir *.txt /o:d') do ( set fileLine=%%a set fileDate=!fileLine:~0,10! if !file...
by stephjo
20 Aug 2015 07:35
Forum: DOS Batch Forum
Topic: Listing file names (primary file name & file extension)
Replies: 1
Views: 834

Listing file names (primary file name & file extension)

Hello, I would like to list files in a directory into a new text file. Each file name is 8.3 characters, with 8 characters for the primary file name, a dot, and file extension of 3 characters. For every file, I would like the primary file name in one line and file extension in the following line. Ho...
by stephjo
03 Feb 2014 08:41
Forum: DOS Batch Forum
Topic: Reading tab and new line characters
Replies: 4
Views: 1559

Re: Reading tab and new line characters

Foxidrive: Thank you. The "tokens=*" to "delims=" displays tabs. How about empty lines (consecutive new line characters?)
by stephjo
03 Feb 2014 02:48
Forum: DOS Batch Forum
Topic: Reading tab and new line characters
Replies: 4
Views: 1559

Reading tab and new line characters

Hi folks, I am working on a simple script that can read a file and display contents line-by-line. The following script (from another thread here) doesn't display the new line and tab characters in the read file. My hunch is that the solution is rather simple, but I can't seem to figure it out. Could...