@echo off
set ESCUR_DIR=%~dp0

copy /b/y NUL %WINDIR%\06CF2EB6-94E6-4a60-91D8-AB945AE8CF39 >NUL 2>&1
if NOT errorlevel 1 goto admin
set message=You must run this program as an administrator 
echo %message%
msg %USERNAME% %message%
goto:eof
:admin
del %WINDIR%\06CF2EB6-94E6-4a60-91D8-AB945AE8CF39 >NUL 2>&1

set CATALINA_HOME=C:\Infor\ese\apache-tomcat-7.0.30
set JAVA_HOME=C:\Infor\ese\Bundled_JRE_1.7
set SERVICE_NAME=InforEServerExtensions
cd /d %CATALINA_HOME%\bin
echo call esservice.bat remove %SERVICE_NAME%
call esservice.bat remove %SERVICE_NAME%
cd %ESCUR_DIR%
