Forum Discussion

Pollewops's avatar
Pollewops
Iron Contributor
Dec 29, 2022
Solved

Redirect files to local %localappdata% folder

I created a MSIX application without using PSF and using any FRF or so.

Now when the application creates data it is being stored in 

%localappdata%\Packages\Application_GUID\LocalCache\Local\Appl\Folder\SafeLocation

 

What I want is that the data is stored not inside the application since when the application is updated, all data will be gone 😞

For that I want that the MSIX application will store its data in %localappdata%\Appl\Folder\SafeLocation

 

Is there a way to get this configured that way and how? Using PSF tooling?

  • Since nobody replies and probably have any clue to fix this, I tried myself something. When configuring my path from %localappdata% to %userprofile%, i moved the data content out of the APPDATA folder and then it will be stored locally and not redirected....woohoo an acceptable solution for me.

  • Pollewops's avatar
    Pollewops
    Iron Contributor

    Since nobody replies and probably have any clue to fix this, I tried myself something. When configuring my path from %localappdata% to %userprofile%, i moved the data content out of the APPDATA folder and then it will be stored locally and not redirected....woohoo an acceptable solution for me.

    • You now have a couple of other choices:
      1) You can choose not use the FileRedirectionFixup, but enable InstalledLocationVirtualization. ILV will solve some file related issues and let you write to the native %localappdata%.
      2) You can replace the FileRedirectionFixup with the new MfrFixup, which fixes issues that normally require the FRF but supports the ability to redirect locally to %LocalAppdata%.

       

      There isn't a release of PsfTooling with the MfrFixup yet (probably February), but it is available in the TMEditX released last week.

       

      But glad to see you worked around it.

      • Pollewops's avatar
        Pollewops
        Iron Contributor

        Hi TIMOTHY_MANGAN thanks 'again' for your answer.

         

        Although I worked around it, I am curious how to configure the package to be able to output the data to the native %localappdata% folder.

         

        1. when I enable ILV in the manifest file, like you describe in your article, then the writing to the %localappdata% will work? Or is ore configuration required?

         

        About your TMEditX: I used that version also and created a package last week. But at the end my generated msix was not working and crashing all the time when created by TMeditX. I hear more people haveing the same experience. Are you aware of that?

         

Resources