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.
我想检测何时将新文件添加到现有文件夹并访问它。
我该怎么做(C#)?
谢谢
请参阅FileSystemWatcher
你应该看看System.IO.FileSystemWatcher,这是你可能想要使用的类。
使用FileSystemWatcher 类
使用 FileSystemWatcher 类在创建、更新文件等时引发事件。
文件系统观察器
我不是 Windows 老兄,但一般来说,找出是否有一个 Windows API 调用允许您查看目录。