@echo off cls color 1b setlocal %~d0 cd "%~dp0" chcp | find "866" >NUL if errorlevel 1 chcp 866 >NUL :_main cls echo. echo [1] Аccoциировать EmEditor с файлами echo. echo [2] Восстановить файловые ассоциации по умолчанию echo. echo. set _choice= set /p _choice= Нажмите [ENTER] для отмены и выхода или введите вариант [1/2]: if "%_choice%" == "" goto _quit if "%_choice%" == "1" goto _inst if "%_choice%" == "2" goto _uninst goto _main :_inst cls reg add "HKCR\.cfg" /ve /d "inifile" /f >NUL reg add "HKCR\.ini" /ve /d "inifile" /f >NUL reg add "HKCR\.inf" /ve /d "inffile" /f >NUL reg add "HKCR\.reg" /ve /d "regfile" /f >NUL reg add "HKCR\.log" /ve /d "notepad_file" /f >NUL reg add "HKCR\.txt" /ve /d "notepad_file" /f >NUL reg add "HKCR\htmfile\shell\edit\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\htmlfile\shell\edit\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\inffile\shell\open\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\inifile\shell\open\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\txtfile\shell\open\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\txtfile\DefaultIcon" /ve /d "%cd%\EmEditor.exe,0" /f >NUL reg add "HKCR\xlsfile\shell\edit\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\xmlfile\shell\edit\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\notepad_file\DefaultIcon" /ve /d "%cd%\EmEditor.exe,0" /f >nul reg add "HKCR\notepad_file\shell\Open\command" /ve /d \""%cd%\EmEditor.exe\" \"%%1"" /f >NUL reg add "HKCR\notepad_file\shell\Open\ddeexec\Application" /ve /d EmEditor /f >NUL reg add "HKCR\notepad_file\shell\Open\ddeexec\Topic" /ve /d System /f >NUL cls echo. echo Готово. Нажмите любую клавишу для выхода . . . pause >NUL goto _quit :_uninst cls reg add "HKCR\.cfg" /ve /d "inifile" /f >NUL reg add "HKCR\.ini" /ve /d "inifile" /f >NUL reg add "HKCR\.inf" /ve /d "inffile" /f >NUL reg add "HKCR\.reg" /ve /d "regfile" /f >NUL reg add "HKCR\.log" /ve /d "notepad_file" /f >NUL reg add "HKCR\.txt" /ve /d "notepad_file" /f >NUL reg add "HKCR\htmfile\shell\edit\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\htmlfile\shell\edit\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\inffile\shell\open\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\inifile\shell\open\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\inifile\DefaultIcon" /ve /d "%SystemRoot%\system32\shell32.dll,-151" /f >NUL reg add "HKCR\regfile\shell\edit\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\txtfile\shell\open\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\txtfile\DefaultIcon" /ve /d "%SystemRoot%\system32\shell32.dll,1" /f >NUL reg add "HKCR\xlsfile\shell\edit\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\xmlfile\shell\edit\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\notepad_file\DefaultIcon" /ve /d "%SystemRoot%\system32\shell32.dll,70" /f >NUL reg add "HKCR\notepad_file\shell\Open\command" /ve /d "notepad.exe %%1" /f >NUL reg add "HKCR\notepad_file\shell\Open\ddeexec\Application" /ve /d notepad /f >NUL reg add "HKCR\notepad_file\shell\Open\ddeexec\Topic" /ve /d System /f >NUL cls echo. echo Готово. Нажмите любую клавишу для выхода . . . pause >NUL goto _quit :_quit endlocal exit |