简体   繁体   English

以编程方式访问Windows 8.1中最常用的应用程序

[英]Programmatically access most frequently used apps in Windows 8.1

The Windows 8.1 start menu provides a list of apps that can be sorted by most used (Windows Button > Down arrow > Apps: by most used). Windows 8.1开始菜单提供了可以按最常用的方式排序的应用程序列表(Windows按钮>向下箭头>应用程序:最常用)。 Is there a way to programmatically get a list of these apps in this order in C#? 有没有办法以编程方式在C# 中按此顺序获取这些应用程序的列表? If not in this order, at least a list of the most used and/or moderately used apps as displayed in the Windows 8.1 start menu? 如果不按此顺序,至少是Windows 8.1开始菜单中显示的最常用和/或适度使用的应用程序列表?

The answer is probably yes, you can, though it's not recommended (nor easy). 答案可能是肯定的,你可以,虽然不推荐(也不容易)。

Raymond Chen described this pretty clearly in his blog post, "Why is there no programmatic access to the Start menu pin list?" Raymond Chen在他的博客文章中清楚地描述了这一点, “为什么没有编程访问开始菜单引脚列表?” . It talks about a different issue on Windows XP, but I think the moral of the story applies here as well, that this information is too easily abused and thus no public API is available. 它谈到了Windows XP上的一个不同的问题,但我认为这个故事的道德也适用于这个,这个信息太容易被滥用,因此没有公共API可用。 Stackoverflow also has a question that addresses the MFU list directly (see this question ), and the answers are that you just shouldn't do it. Stackoverflow还有一个直接解决MFU列表的问题 (请参阅此问题 ),答案是您不应该这样做。

The thing is, the MFU list you see is stored in the UserAssist section of the registry, and its values are encrypted (used to be ROT13, but I have no idea for 8.1). 问题是,您看到的MFU列表存储在注册表的UserAssist部分,其值是加密的(以前是ROT13,但我不知道8.1)。 Didier Stevens wrote a GUI that decrypts the values (see blog post ), but it has not been updated since 8.1 came out. Didier Stevens编写了一个解密这些值的GUI(参见博客文章 ),但自8.1发布以来,它还没有更新。 For what its worth the author has included the source code but it's for an older version. 作为其价值,作者已经包含了源代码,但它适用于旧版本。 You can probably expand on his code to make it support 8.1 if you can do cryptanalysis. 如果你能进行密码分析,你可以扩展他的代码,使其支持8.1。

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM