locked
Accessing the registry RRS feed

  • Question

  • Is there a way to get the value of a specific key from the registry via the provided JS-functions?

    -- Dave


    • Edited by D. Hainzl Sunday, September 18, 2011 7:26 PM
    Sunday, September 18, 2011 7:26 PM

Answers

  • Is there a way to get the value of a specific key from the registry via the provided JS-functions?

    -- Dave



    Hello, Dave.

    Metro apps cannot access the Windows Registry. Instead, use WinRT API's Windows.Storage.ApplicationData.locaSetings/roamingSetting.

    What are you trying to do that requires that you access a registry value?

    Thanks, Chris (I work for the AppX team)

    Sunday, September 18, 2011 10:12 PM

All replies

  • Is there a way to get the value of a specific key from the registry via the provided JS-functions?

    -- Dave



    Hello, Dave.

    Metro apps cannot access the Windows Registry. Instead, use WinRT API's Windows.Storage.ApplicationData.locaSetings/roamingSetting.

    What are you trying to do that requires that you access a registry value?

    Thanks, Chris (I work for the AppX team)

    Sunday, September 18, 2011 10:12 PM
  • Suppose there is a traditional Windows app that has values in the registry that a metro app needs access to to handle some intergration or informaiton display.  How do we get access to this data?

     

    Seems to me that the MS team has assumed an ideal world where it is all metro and not a mixed, transitional environment where metro and traditional MFC/.Net apps have to co-exist and interact.  PLEASE FIX THIS!

    Tuesday, September 27, 2011 11:44 AM
  • There is a strict distintion between Metro and Desktop apps. Metro apps run in a sandboxed environment for security reasons. Desktop apps do not have any restrictions.

    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.

    A better approach, since you're likely referring to a LOB app, is to store those user settings in a web service that is acccessed from both applications. This would allow them to very easily be shared across both Metro and Desktop apps. And, not only that but would allow those settings to roam across devices too.


    Microsoft MVP - Bing Maps
    Blog: http://pietschsoft.com | Web.Maps.VE - ASP.NET AJAX Bing Maps Server Control
    Tuesday, September 27, 2011 3:29 PM
  • 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.
    Wednesday, September 28, 2011 8:30 PM
  • I'm thinking the same solution and came across this topic and the last reply suggests talk to localhost (a http server in my case) is not allowed. Is there Microsoft staff can confirm this? Thanks.
    Tuesday, January 17, 2012 11:28 PM
  • How about the Classic app just writes a file to the folder where the Metro app is installed (or another shared location, network drive, etc)?

    SQL MCP

    Monday, March 5, 2012 8:41 PM