views:

83

answers:

1

I am trying to get the filename of a word document or any other window for that matter while some dialog box like Save as or Open or Print etc. is open. Can anybody give me an example of how to implement this in C#.

Thanks!

Saurabh

+1  A: 

Windows API can give you the name of the application which occupies a particular window, but to know what file (or files) are open within that application would require OLE automation or some other API supplied by the application (here winword.exe) itself.

mjv