Код:

@echo off
>nul chcp 1251
set "file=1.txt"
set "search=Мама мыла раму."
set "n=99"
(
for /f "delims=" %%i in ('
^<"%file%" find/i /n "%search%"^| findstr/bl [%n%]
') do (
set x=%%i
>nul chcp 866
cmd/v/c echo[!x:*]^^=!
)
)|| echo Not found.
pause>nul
exit/b