It is necessary to open a file in a loop (the file can be replenished with data at this time) until the desired line is found and the phrase is not found to show the loading indicator.
r /f %%i in ('findstr /v ^# myfiletxt') do ( find "fraza" ) %%i Offhand like this:
@echo off echo. :cycle for /f %%i in ('findstr /M /C:"Искомый Текст" c:\folder\filename.log') do ( goto done ) type x:\folder\symbol.txt goto cycle :done The file x: \ folder \ symbol.txt must exist and contain exactly 1 byte of that symbol with which the progressor will be drawn. For example, an asterisk ... And the speed of the progress of the progressor will be determined solely by the speed of checking the file for the desired (sub) line. And most likely it will be VERY quickly - so that before the goto cycle you can invent a forced pause for a second, or even two ...
If you wish, you can count the drawn characters, and upon reaching 79, send another file, with a single LF character.
Source: https://ru.stackoverflow.com/questions/623084/
All Articles