简体   繁体   English

如何创建指向存储在Internet /云中但在Windows资源管理器中显示为“本地文件”的文件的链接?

[英]How to create a link to a file stored in internet / cloud but appears as a 'local file' in Windows Explorer?

Similar to OneDrive's "Files On-Demand" as well as DropBox's "Smart Sync" functionality, I am curious how to create a file that appears to be on local disk normally but is actually linked / stored in the internet or cloud. OneDrive的“按需文件”以及DropBox的“智能同步”功能相似,我很好奇如何创建一个看上去通常位于本地磁盘上但实际上已链接/存储在Internet或云中的文件。

I think this is different from .lnk or .url files as they retain the following even if they are stored on the cloud: 我认为这与.lnk或.url文件不同,因为即使它们存储在云中,它们也保留以下内容:

  • filetype (.pdf, .xlsx, etc.) 文件类型(.pdf,.xlsx等)
  • location on disk (eg folder path) 磁盘上的位置(例如文件夹路径)
  • size (original file size though size on disk is 0 ) 大小(尽管磁盘大小为0,但原始文件大小)
  • file icon 文件图标

Is there another type of file or any metadata that tells Explorer that a particular file should be retrieved from the internet when it is accessed? 是否存在另一种类型的文件或任何元数据,告诉资源管理器在访问特定文件时应从互联网上检索该文件?

I don't know how the others do it but if I was creating something like this I'd have my client program create the dummy 0 size files with a unique extension that I have registered to my program then when the user double clicks on it, window will try to open the file with my program and I read the file name and do the work to download the file to some temp folder so the user can view it. 我不知道其他人是怎么做的,但是如果我正在创建类似的东西,我会让我的客户端程序创建一个虚拟的0大小的文件,该文件具有我已经注册到程序中的唯一扩展名,然后当用户双击它时,窗口将尝试使用我的程序打开文件,然后我读取文件名,并进行工作以将文件下载到某个临时文件夹中,以便用户查看。

Further you could monitor the temp folder so that if the user saves any changes you could upload those changes to your cloud location. 此外,您可以监视temp文件夹,以便如果用户保存任何更改,则可以将这些更改上载到您的云位置。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Selenium:在Internet Explorer中将文件下载到指定的文件夹,而无需直接链接,没有Windows窗体,没有AutoIt或Robot - Selenium: download file in Internet Explorer to specified folder without direct link, without Windows Forms, without AutoIt or Robot 如何创建打开本地文件的链接? - How create a link to open local file? 如何将文件写入Response for Internet Explorer Mobile? - How to write a file to the Response for Internet Explorer Mobile? 可以为Windows Phone创建文件资源管理器吗? - Would it be possible to create a file explorer for Windows Phone? 如何枚举真正的 Windows 文件资源管理器窗口 - How to enumerate the real Windows File Explorer windows Windows文件浏览器控件 - Windows File Explorer control 如何以编程方式在Windows 10资源管理器的导航窗格中创建指向文件夹的链接 - How to create link to folder in navigation pane of Windows 10 explorer programmatically 如何在Windows File Explorer中选择多个文件 - How to select multiple files in windows file explorer 如何在 Windows 应用程序上识别文件名,该文件在 Windows 资源管理器上单击? - How to identify file name on Windows applicatoin that file is clicked on Windows explorer? (如何)使用Windows文件资源管理器查找应用程序? - (How to) Use Windows file explorer to find an application?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM