Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试获取 word 文档或任何其他窗口的文件名,而另存为或打开或打印等对话框已打开。谁能给我一个如何在 C# 中实现它的例子。
Windows API 可以为您提供 占据特定窗口的应用程序的名称,但要知道在该应用程序中打开了哪些文件(或多个文件),则需要 OLE 自动化或应用程序(此处为 winword.exe)本身提供的一些其他 API。