Microsoft
Software
Hardware
Network
Question : Batch File Check For Numeric Digits
Hi,
So here's the situation, I need to create a batch file that will look at a text file in the same directory - if the text file has no numbers in it - it will skip the section and move to the next step. If there are numbers than it should execute a command and then move to the next step.
The text files will always be a constant name, I will be creating multiple for different reports.
Any thoughts or programs that I can use to do this?
Thanks,
Ryan
Answer : Batch File Check For Numeric Digits
@echo off
findstr /R /C:"[0-9]" test.txt > NUL
if "%ERRORLEVEL%"=="1" goto nonumbers
echo Found Numbers
goto end
:nonumbers
echo No numbers
:end
Random Solutions
How to Improve search functionality in ASP.NET 1.1?
Asp.net ajax error. the same if 'mdPopup' cannot be added to the application.
Need to convert lotusscript to work with macintosh
Uninstalling DFS Service
WEBBRICK
IE8 - minimized windows - same url - change names
Check if EJB is invioked
Forefront TMG source IP address spoofed issue
Wyse thin client and Citrix display/graphic lag
Dell Poweredge 1800 SBS 2003 reboots at 'Applying Computer Settings'