Create stand alone app without GUI?
5 次查看(过去 30 天)
显示 更早的评论
I have a simple Matlab script that selects a few Excel files from a given folder, reads-in the data and does some simple data processing saving the results in another Excel file. I select the folder with the needed files using uigetdir.
I've created a stand alone app for it, but when I run it nothing happens, I don't get the pop-up to select the folder with the files, I only get the splash screen. The app name appears in the Task Manager and stays there... What am I doing wrong?
2 个评论
dpb
2021-4-10
编辑:dpb
2021-4-10
Dunno...haven't tried but where is the code that calls uigetdir located in the app?
I've been building an app that does similar thing -- before I put any GUI stuff into it, it ran as you describe but did execute the code to read the input Excel files and wrote the output one with only the splash screen visible. So, the code ran as intended to do the work; just no user interaction at all.
In my case, wanting it basically to be "no hands needed!" for the most common usage, I added a menu to let the user change the default input/output files instead of trying to call uigetdir from the inline code, but all worked that way. The call to uigetdir is in the menu callback function.
If you don't want the menu at all, I don't see why a uigetdir call wouldn't be executed if in the startup section, though, but I've not tried just that by its lonesome.
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Startup and Shutdown 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!