|Do you mean you want to know where the actual file is, that Notepad current has open? Unfortunately, Notepad doesn't tell you what file it is editing - the title bar tells you the file name only, but not its location.|
One way to find where the file is is to use Process Monitor from SysInternals.com and have it monitor file creations.
Another way is, if you have a build tool that can create executable files, is to write a small program that echos its command-line arguments, and temporarily replace Notepad.exe in system32 with your program.
[Edit: our lines crossed - I was replying to your initial post.]