FAQ |
Kalender |
![]() |
#2 | ||
|
|||
Klarade millennium-buggen
|
Här är ett exempel på hur du kan lösa problemet:
Kod:
@echo off :: : SeekText.bat - Test if pattern in string : Param1 - the pattern : Param2 - the string to check :: echo.%2 | findstr /C:"%1" 1>nul if errorlevel 1 ( echo. Returnerade 1 - pattern not found goto inget ) ELSE ( echo. Returnerade 0 - found pattern goto hittat ) goto end :inget echo Hittade INGET intressant... goto end :hittat echo Hittade vad vi ville ha! goto end :end echo Done. Så här kan du använda batfilen: Kod:
SeekText "test.se" "test.se/test/hej/pelle" Senast redigerad av Conny Westh den 2013-03-19 klockan 00:19 |
||
![]() |
![]() |
|
|