Compiled App: previously accessible file is now inaccessible

6 visualizzazioni (ultimi 30 giorni)
I am creating an app using MATLAB 2020a and AppDesigner. As part of the app, I have functionality whereby one can enter some parameters and the app saves them into a .m file in a specific folder using fprintf commands. The app then reloads a listbox with the filenames of all files in the folder, including the new file, and allows users to view their parameters/ When testing in the AppDesigner environment, it works perfectly. However, when I compile, I get the error "Previously accessible file is now inaccessible." For some background, the app has default files already in the same folder and the app is able to read these files with no issue. It's only when I create new files that it throws that error. I'm also running this on a Windows 10 PC FYI.
Steps taken so far:
  • I confirmed the file was saved successfully.
  • I manually navigated to the temp folder where the files are saved and visually confirmed that the files (default and new) are there.
  • I opened the new file directly to make sure it wasn't an empty file.

Risposte (1)

Steven Lord
Steven Lord il 21 Gen 2022
From the documentation: "MATLAB Runtime only works on MATLAB code that was encrypted when the deployable archive was built. Any function or process that dynamically generates new MATLAB code will not work against MATLAB Runtime."

Categorie

Scopri di più su App Building in Help Center e File Exchange

Prodotti


Release

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by