MATLAB Answers

li xu
1

Why the file path get wrong after I packed my app code written by App Designer to a Web App?

Asked by li xu
on 11 Sep 2019
Latest activity Commented on by li xu
on 18 Sep 2019
I am currently using App Designer to create an app. It needs to import an Excel file and the interface will show the file path. This is my code to show the path:
% Button pushed function: ChoosebasinshapefileButton
function ChoosebasinshapefileButtonPushed(app, event)
[shapeName, shapefolder] = uigetfile();
shapeFileName = fullfile(shapefolder, shapeName);
app.EditField_3.Value = shapeFileName;
end
It shows the correct file path when I run the app in App Designer, as shown blow:
But, after I packed my App and run it as a Web App using the MATLAB Compiler, it shows the wrong file path, as shown below (same file as before):
So, does anyone know why this happen? And how should I do to solve it? Any help appreciated. I am using ver R2019a
Thank you very much!
Li

  0 Comments

Sign in to comment.

1 Answer

Answer by Cris LaPierre
on 11 Sep 2019
 Accepted Answer

Not sure it provides much of a description, but you can read a little about in this answer.

  1 Comment

Sign in to comment.