How can I copy values from UITABLE placed in UIFIGURE to clipboard?
이전 댓글 표시
I created matlab application using App Designer and it contains uitable. I am trying to copy selected values from the table to Excel using CTRL + C command. It worked with uitable created using GUIDE.
채택된 답변
추가 답변 (1개)
Y.S.
2022년 6월 22일
0 개 추천
I'm using Matlab R2021a
If you define a ContextMenu, you can assign 'Accelerators'
when I select the accelerator 'C', the keypress CTRL-C automatically initiales the callback (see screenshot)
as for the actual copy-paste; I followed https://nl.mathworks.com/matlabcentral/answers/1854-copy-utiable-to-excel, which read uitable as a string. using e,.g. textscan you can format the string with tabs ('\t') or linebreaks ('\n') to make it suited to copy in a nice formatted way directly (and into e.g. Excel).

카테고리
도움말 센터 및 File Exchange에서 Spreadsheets에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!