Got the solution and it's working fine. Set the environment variables as:
CATALINA_HOME=C:\Program Files\Java\apache-tomcat-7.0.59\apache-tomcat-7.0.59
(path where your Apache Tomcat is)JAVA_HOME=C:\Program Files\Java\jdk1.8.0_25;
(path where your JDK is)JRE_Home=C:\Program Files\Java\jre1.8.0_25;
(path where your JRE is)CLASSPATH=%JAVA_HOME%\bin;%JRE_HOME%\bin;%CATALINA_HOME%\lib