与WindowsAPICodePack的文件关联 [英] File associations with the WindowsAPICodePack

查看:113
本文介绍了与WindowsAPICodePack的文件关联的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我正在使用WindowsAPICodePack,我对Windows如何处理文件类型有一些疑问.

作为API的一部分,您可以使用
向应用程序注册文件类型关联

Hi all,

I''m playing about with the WindowsAPICodePack and i''ve got a few queries regarding how Windows deals with file types.

As part of the API you have the ability to register filetype associations with your application using

RegisterFileAssociations(string progId,
            bool registerInHKCU, string appId, string openWith,
            params string[] extensions)



操作非常简单,一旦完成,您就可以让Windows跟踪您最近打开的文件.

但是文件夹呢? Windows如何处理它们?是否有与资源管理器关联的文件夹的文件扩展名.是否可以将程序与文件夹关联?

我知道需要提供大量信息,但我花了很长时间尝试过滤掉Google上的大量信息,以期加深了解.

我通常不做任何winforms或shell编程(Web开发人员)
所以这对我来说是全新的.我只是想为一个文章拼凑一个程序.

在此先感谢您的耐心配合和建议.


更新**********************
基本上,我希望模仿Windows资源管理器最近的文件夹跳转列表的行为,但是我在文档中找不到允许此操作的任何方法.

我的应用程序处理了一批文件,因此最好使用跳转列表来添加重新打开文件夹的功能.



Simple enough to follow and once done you can have windows keep track of your recently opened files.

But what about folders? How does Windows deal with them? Is there a file extension for folders that is associated with Explorer. Is it possible to associate your program with folders?

I know that''s quite a bit of info to request but I''ve spent quite a while trying to filter through a lot of guff on Google trying to patch together a greater understanding.

I don''t normally do any winforms or shell programming (web developer)
so this is all new to me. I''m just trying to piece together a program for an article.

Many thanks in advance for your patience and advice.


Update**********************
Basically I would lke to mimic the behaviour of Windows Explorers recent folders jumplist but I can''t find any methods in the documentation that allow this.

My application processes batches of files so it would be nice to add the ability to reopen folders using a jumplist.

推荐答案

文件关联不适用于文件夹.但是,Windows中有特殊和自定义文件夹的概念.有关更多信息,请参见下面的链接:

http://en.wikipedia.org/wiki/Special_Folders [ http://msdn.microsoft.com/en-us/library/s2esdf4x(VS .80).aspx [ ^ ]
File associations do not apply to folders. However, there is a concept of Special and Custom folders in Windows. See the links below for more information:

http://en.wikipedia.org/wiki/Special_Folders[^]

http://msdn.microsoft.com/en-us/library/s2esdf4x(VS.80).aspx[^]


这篇关于与WindowsAPICodePack的文件关联的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆