In the Notepad++ run box, use the ... button and find your batch file. Double clicking it will move full path to the run box; then add $(FULL_CURRENT_PATH) to the run box. The run box should look something like this:
compile_a_java_program.bat $(FULL_CURRENT_PATH)
If necessary, add path info for your batch file.
You batch file might need a tweak or two:
@echo off
javac %1
cd /d %~dp1
java %~n1
pause
I threw in the
pause so you can see the result before the window closes. I also added a
CD command to navigate to the directory where the class file lives, just in case the directory is not on the
classpath variable.
Good luck.