I am writing a screen capture application for a client. Part of the capture is fine, but he wants to get the name and path to the file where the capture is located.
Using system.diagnostics.process I can get the process in which the capture is performed, and can get the full path to the EXE, but not the file that is open.
t. Notepad is open with TextFile1.txt as a document. I can get from the MainWindowTitle process which will be "TextFile1.txt - Notepad", but what I need is more like "c: \ users .... \ TextFile1.txt"
Is there a way to get more information from the process?
I am sure there is a way, but I cannot figure it out
Any help is greatly appreciated.
source
share