@echo off
set split=+-----------------------+
:main
cls
echo What do you want?
echo %split%
echo ^| list: ^|
echo %split%
echo ^| [1] Start Services ^|
echo ^| [2] Stop Services ^|
echo %split%
echo ^| [E] EXIT ^|
echo %split%
set Choice=
set /P Choice=Your Choice:
echo ----------------------------------
if /I "%Choice%"=="" goto main
if /I "%Choice%"=="1" goto start
if /I "%Choice%"=="2" goto stop
if /I "%Choice%"=="E" goto exit
goto main
:start
cls
echo Which service do you want to start?
echo %split%
echo ^| list: ^|
echo %split%
echo ^| [1] Apache2.2 ^|
echo ^| [2] MySQL ^|
echo ^| [3] andLinux ^|
echo ^| [4] MSSQL ^|
echo ^| [5] VMware Authorization Service ^|
echo ^| [6] VMware DHCP Service ^|
echo ^| [7] VMware Virtual Mount Manager Extended ^|
echo ^| [8] VMware NAT Service ^|
echo %split%
echo ^| [Q] QUIT ^|
echo %split%
set Choice=
set /P Choice=Your Choice:
echo ----------------------------------
if /I "%Choice%"=="" goto start
if /I "%Choice%"=="1" goto sta1
if /I "%Choice%"=="2" goto sta2
if /I "%Choice%"=="3" goto sta3
if /I "%Choice%"=="4" goto sta4
if /I "%Choice%"=="5" goto sta5
if /I "%Choice%"=="6" goto sta6
if /I "%Choice%"=="7" goto sta7
if /I "%Choice%"=="8" goto sta8
if /I "%Choice%"=="Q" goto main
goto start
:sta1
net start Apache2.2
echo Apache has started.
goto ask
:sta2
net start MySQL
echo MySQL has started.
goto ask
:sta3
net start andLinux
echo andLinux has started.
goto ask
:sta4
net start MSSQLSERVER
echo MSSQLSERVER has started.
goto ask
:sta5
net start "VMware Authorization Service"
echo VMware Authorization Service has started.
goto ask
:sta6
net start "VMware DHCP Service"
echo VMware DHCP Service has started.
goto ask
:sta7
net start "VMware Virtual Mount Manager Extended"
echo VMware Virtual Mount Manager Extended has started.
goto ask
:sta8
net start "VMware NAT Service"
echo VMware NAT Service has started.
goto ask
:stop
cls
echo Which service do you want to stop?
echo %split%
echo ^| list: ^|
echo %split%
echo ^| [1] Apache2.2 ^|
echo ^| [2] MySQL ^|
echo ^| [3] andLinux ^|
echo ^| [4] MSSQL ^|
echo ^| [5] VMware Authorization Service ^|
echo ^| [6] VMware DHCP Service ^|
echo ^| [7] VMware Virtual Mount Manager Extended ^|
echo ^| [8] VMware NAT Service ^|
echo %split%
echo ^| [Q] QUIT ^|
echo %split%
set Choice=
set /P Choice=Your Choice:
echo ----------------------------------
if /I "%Choice%"=="" goto stop
if /I "%Choice%"=="1" goto sto1
if /I "%Choice%"=="2" goto sto2
if /I "%Choice%"=="3" goto sto3
if /I "%Choice%"=="4" goto sto4
if /I "%Choice%"=="5" goto sto5
if /I "%Choice%"=="6" goto sto6
if /I "%Choice%"=="7" goto sto7
if /I "%Choice%"=="8" goto sto8
if /I "%Choice%"=="Q" goto main
goto stop
:sto1
net stop Apache2.2
echo Apache has stoped.
goto ask
:sto2
net stop MySQL
echo MySQL has stoped.
goto ask
:sto3
net stop andLinux
echo andLinux has stoped.
:sto4
net stop MSSQLSERVER
echo MSSQLSERVER has stoped.
goto ask
:sto5
net stop "VMware Authorization Service"
echo VMware Authorization Service has stoped.
goto ask
:sto6
net stop "VMware DHCP Service"
echo VMware DHCP Service has stoped.
goto ask
:sto7
net stop "VMware Virtual Mount Manager Extended"
echo VMware Virtual Mount Manager Extended has stoped.
goto ask
:sto8
net stop "VMware NAT Service"
echo VMware NAT Service has stoped.
goto ask
:ask
echo ----------------------------------
set Choice=
set /P Choice=Start Others?(y/n)
if "%Choice%"=="y" goto main
:exit
exit