i know the use of java.exe and javaw.exe in command console.. but how they are used in eclipse?
Could you please explain a bit what you are trying to do?
If you want to launch a program, using "Run" and "Run as" will do the trick. You can also configure it to use command-line options, environment variables, etc
Eclipse should call java.exe javaw.exe when you click on Run As -> Java Application You also can select which exe to uses in the run-settings
AFAIK, Eclipse uses javaw.exe to run; this is the java process that doesn't use a CMD console window.
Java.exe is sometimes launched by Eclipse, to run projects or servers from within the IDE.
The Eclipse launcher uses javaw internally to launch Eclipse. You can see the settings in eclipse.ini file in your installation. This letsyou to easily identify Eclipse in the list of processes in the task manager instead of seeing another Java process.
When you Run/Debug Java programs inside Eclipse, it defaults to using Java to launch another jvm, but I believe you can set it to use javaw if need. Some launchers use javaw by default, I think the tomcat launcher (in WTP) is one of them.