Export Table from Matlab Guide to Excel

4 ビュー (過去 30 日間)
Miss B
Miss B 2020 年 3 月 25 日
コメント済み: Adam Danz 2020 年 3 月 27 日
Hello everyone!
I am having serious trouble trying to export a TABLE from MATLAB GUIDE to EXCEL with a PUSH BUTTON.
How would I go about coding this exactly under a push button?
And under which function would I code this under?
Thank you very much for your help!
  12 件のコメント
darova
darova 2020 年 3 月 26 日
i just want someone to pay me
I want 2000 reputation points
Adam Danz
Adam Danz 2020 年 3 月 27 日
@Miss B, please understand why it was important to confirm that the entire error message was shared because this will help you troubleshoot in the future. Below is a typical, complete error message produced from within a GUIDE GUI named save_table. The error message you shared only contained the last 5 lines but critical information is in the first few lines which seemed to have been missing from the error message you shared.
Also notice that the error message you shared doesn't mention xlswrite at all. So, it must be the case that either 1) the error wasn't caused by xlswrite or 2) parts of the error message was missing. Or, maybe you resolved that error on your own and were having a different problem that wasn't communicated effectively.
We can't suggest solutions before we understand the problem and I know it's often difficult to explain the problem (it's like me describing the sounds my car's making to the mechanic).
Not enough input arguments. % <-- %
Error in save_table>pushbutton1_Callback (line 85) % <-- This part seems %
cla(handles.axes1) % <-- to be missing %
Error in gui_mainfcn (line 95) % <-- from your error %
feval(varargin{:}); % <-- message. %
Error in save_table (line 19)
gui_mainfcn(gui_State, varargin{:});
Error in
matlab.graphics.internal.figfile.FigFile/read>@(hObject,eventdata)save_table('pushbutton1_Callback',hObject,eventdata,guidata(hObject))
Error while evaluating UIControl Callback.

サインインしてコメントする。

採用された回答

Sean de Wolski
Sean de Wolski 2020 年 3 月 26 日
This would be a lot easier in App Designer because the uitable data can just be a MATLAB table. I'd strongly encourage you to move to app designer. And in R2020a, the migration tool (has existed but is greatly improved) has made it even easier.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeInteractive Control and Callbacks についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by