如何创建一个几乎包含其他 2 个目录内容的目录
Windows 7 中有没有办法创建一个目录,该目录的虚拟内容包含其他 2 个实际目录中的所有文件和文件夹?
我希望我可以定义一个目录,通过符号链接或其他方式反映其他 2 个目录的内容,而无需复制文件。
*编辑:我需要能够将组合目录指定为文件路径。看起来使用图书馆不允许我这样做。
c:\actualdir1\ a,b
c:\actualdir2\ c,d
c:\virtualdir\ a,b,c,d
谢谢
Is there a way in Windows 7 to create a directory that has as its virtual contents all the files and folders from 2 other actual directories?
I'm hoping I can define a single dir that reflects the contents of 2 other dirs via symblinks or something without having to copy files.
*edit: I need to be able to specify the combining dir as a filepath. Looks like using a library doesn't let me do this.
c:\actualdir1\ a,b
c:\actualdir2\ c,d
c:\virtualdir\ a,b,c,d
thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
看来图书馆是完美的选择。您可以创建一个库并通过代码向其中添加文件夹,然后在几乎任何需要使用文件夹的地方使用该库。您没有提及要使用哪种语言 - 对于托管代码,Windows API 代码包有一些 shell 内容的包装器,并且在 C++ 中您可以使用 shell API。
(如果您以用户身份询问,那么答案仍然是图书馆,但问题是题外话,属于超级用户。)
Seems like libraries would be perfect for this. You can create a library and add folders to it from code, then use the library almost anywhere you would use a folder. You don't mention what language you want to use - for managed code the Windows API Code Pack has some wrappers for the shell stuff, and from C++ you can use shell APIs.
(If you're asking as a user then the answer is still libraries, but the question is offtopic and belongs on SuperUser.)
不,我认为如果不编写自己的 Shell 扩展,这是不可能的。但是,根据您要寻找的内容,也许使用 Windows 7 库就可以解决问题。
No, I don't think this is possible without writing your own Shell Extension. However, depending on what you are looking for, perhaps using Windows 7 Libraries would do the trick.