Darfs sonst noch etwas sein ? :-)

@Echo off

if exist "d:\baycom\poc32\status.txt" goto ende

if "%2"=="0" goto ende
if "%2"=="1" goto ende
if "%2"=="2" goto ende
if "%2"=="3" set text=DAU Stoerung

echo %3> d:\temp.txt
ansiasci d:\temp.txt d:\Alarm.txt /an /o


find /c "BMA" d:\Alarm.txt
if %errorlevel%==0 goto ende
REM if %errorlevel%==1 echo Stichwort nicht enthalten

find /c "Ölspur" d:\Alarm.txt
if %errorlevel%==0 goto ende
REM if %errorlevel%==1 echo Stichwort nicht enthalten


cls
Echo Alarmierung
echo "Alarm läuft" > status.txt
d:\baycom\poc32\clemail.exe -to XXXX@gmx.de -from dXYX@gmx.de -fromname %text% -smtpserver mail.gmx.de -popserver pop.gmx.de -popuser 000000 -poppass XXXXX -subjectfile d:\Alarm.txt -bodyfile d:\alarm.txt
wait 30

del status.txt
:ende

Gruß Joachim