You don't. That is, you don't do it using the built in commands, since there is no such thing as a "Get current open file from Notepad" command.
Instead, you grab the SDK from the Developers section and write a quick plugin that will do it for you. If you just want something quick and gross, you could probably just do it with a quick GetWindowText to get the filename from Notepad's toolbar, parse that however you want, and then follow it up with a call to your batch file.
Good luck,
Jeff