How do I import an excel file into app designer?

44 次查看(过去 30 天)
I am using app designer to create an app that will take in a code name as an input and display a row from an excel file as the output. I have an m file that does this and works, but I have not been able to find a way to link app designer with matlab. I was hoping someone might have some guidance on how I can do this. Or knows where there are tutorials for this. The codename can be inputed by clicking the list, or by typing it in. Either way is fine.
  1 个评论
dpb
dpb 2022-10-6
编辑:dpb 2022-10-7
"... find a way to link app designer with matlab."
??? App Designer IS building a MATLAB application; you call your function (m-file) in the callback routine that is the callback from the dropdown component ValueChangedFcn.
There are quite a number of sample applications packaged with MATLAB; several of those use a dropdown and there's uidropdown documentation that has examples of creating and using one by itself to get the hang of it.
But, to clarify, there's nothing different inside App Designer/application code about using user-defined functions in m-files any different than using the same function(s) outside App Designer in MATLAB scripts or other functions. It only has to be on the path to be found just as in MATLAB; when you package the app it will be included in the dependencies list and it's source file will be packaged along with the app file and any data files.

请先登录,再进行评论。

回答(1 个)

Sailesh Kalyanapu
Sailesh Kalyanapu 2022-10-11
I understand that you are using the MATLAB App Designer (to import data from excel in this scenario) and are looking for guidance/resources related to it.
You can refer to the below documentation/examples. These would act as a good starting point :

类别

Help CenterFile 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!

Translated by