locked
Access Windows Registry

    Question

  • Hello,

    Let's say I'm working on an app that needs to access the registry, like a registry cleaner. How can I do this in a Windows 8 Metro app with JavaScript?

    Thanks in advance.

    Sunday, March 25, 2012 3:57 PM

Answers

  • Hi,

    Metro style apps cannot access the registry. For more information have a look at this thread - http://social.msdn.microsoft.com/Forums/en-US/winappswithhtml5/thread/86a0c2a0-f514-4648-8ec7-2a975f58dc73


    Best Regards. When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer. This helps us build a healthy and positive community.

    • Marked as answer by notme123 Monday, March 26, 2012 11:04 AM
    Sunday, March 25, 2012 6:46 PM
  • My recommendation is that you build a desktop app instead of a Metro style app. It could be that you can manage this problem with the final release, but today I would say that it isn't possible.

    Best Regards. When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer. This helps us build a healthy and positive community.

    • Marked as answer by notme123 Monday, March 26, 2012 11:04 AM
    Monday, March 26, 2012 9:33 AM
  • No. Metro style apps cannot access the registry. They are blocked from affecting the system as a whole. Your registry cleaner would need to be a desktop app.

    --Rob

    • Marked as answer by notme123 Friday, June 01, 2012 1:31 AM
    Friday, June 01, 2012 12:41 AM
    Owner
  • Windows Store apps cannot access the registry. They are blocked from affecting the system as a whole. Your registry cleaner would need to be a desktop app.

    --Rob

    • Marked as answer by notme123 Thursday, December 06, 2012 8:29 PM
    Thursday, December 06, 2012 7:54 PM
    Owner

All replies

  • Hi,

    Metro style apps cannot access the registry. For more information have a look at this thread - http://social.msdn.microsoft.com/Forums/en-US/winappswithhtml5/thread/86a0c2a0-f514-4648-8ec7-2a975f58dc73


    Best Regards. When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer. This helps us build a healthy and positive community.

    • Marked as answer by notme123 Monday, March 26, 2012 11:04 AM
    Sunday, March 25, 2012 6:46 PM
  • Can I create a DLL with another framework that can access the registry, and then access the DLL from my Metro app?
    Sunday, March 25, 2012 6:54 PM
  • I don't think that this is possible, because Metro apps are running in a sandbox (similar to Silverlight applications). What's wrong with the suggestions from the thread (like a service)?

    Best Regards. When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer. This helps us build a healthy and positive community.

    Sunday, March 25, 2012 10:11 PM
  • From That Thread:

    You could write a small windows service that exposes a WCF or some other type of web service that you could then consume from within your Metro application. However, I'm not sure if this would pass the testing required for publication in the Windows App Store. Since it has a dependency on a service to be installed on the localhost in order to function.


    Microsoft MVP - Bing Maps
    Blog: http://pietschsoft.com | Web.Maps.VE - ASP.NET AJAX Bing Maps Server Control

    During the BUILD conference, it was mentioned that any network calls to a service on the local machine would be blocked automatically. So no access to localhost.
    Sunday, March 25, 2012 10:19 PM
  • My recommendation is that you build a desktop app instead of a Metro style app. It could be that you can manage this problem with the final release, but today I would say that it isn't possible.

    Best Regards. When you see answers and helpful posts, please click Vote As Helpful, Propose As Answer, and/or Mark As Answer. This helps us build a healthy and positive community.

    • Marked as answer by notme123 Monday, March 26, 2012 11:04 AM
    Monday, March 26, 2012 9:33 AM
  • Is it possible to do it now with the new Release Preview?
    Thursday, May 31, 2012 11:22 PM
  • No. Metro style apps cannot access the registry. They are blocked from affecting the system as a whole. Your registry cleaner would need to be a desktop app.

    --Rob

    • Marked as answer by notme123 Friday, June 01, 2012 1:31 AM
    Friday, June 01, 2012 12:41 AM
    Owner
  • Now that Windows 8 is released, has anything been changed in the final version, or can apps in the Windows Store still not access the registry?

    Thursday, December 06, 2012 4:51 PM
  • Windows Store apps cannot access the registry. They are blocked from affecting the system as a whole. Your registry cleaner would need to be a desktop app.

    --Rob

    • Marked as answer by notme123 Thursday, December 06, 2012 8:29 PM
    Thursday, December 06, 2012 7:54 PM
    Owner