![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1289155/image.png)
an error (not enough input arguments)happens when I save a .mlapp file
4 次查看(过去 30 天)
显示 更早的评论
I am developing an app using app designer.I run the .mlapp file and debug in code view.After debugging,I save the mlapp file,then an error happens: not enough input arguments.I run .mlapp again,then the same error happens.I want to know why,thank you.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1274725/image.bmp)
0 个评论
回答(1 个)
Smit
2023-2-8
Hi,
I understand that you are facing an issue in App Designer where you are getting the “Not enough input arguments” error when you are running your saved app file.
In App Designer you can specify the number of input arguments required for the application to run in the “startupFcn” function.
Look for the defintion of "startupFcn", example is as follows
function startupFcn(app, arg1);
The above line indicates that the application requires one input argument(“arg1”).
You might need to verify the “startupFcn” function in your application to determine whether your application requires any input arguments.
Further to give input arguments to the application you can expand the drop-down list from the “Run” button in the App Designer toolstrip. In the menu there will be an option to add input arguments. Select the option and enter comma separated arguments.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1289155/image.png)
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Develop Apps Using App Designer 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!