Error using uitable in a figure, not uifigure

7 ビュー (過去 30 日間)
Stephani Kanga
Stephani Kanga 2021 年 9 月 8 日
コメント済み: Stephani Kanga 2021 年 9 月 8 日
[~,~,a,kind] = getimage;
P = impixel() ;
[numSelections,numCols] = size(P);
den = 255;
filename = 'manual_clustering_values.xlsx';
% Pre allocating the array for speed
myCellArray = cell(numSelections,3);
for row = 1:numSelections
myCellArray{row,1} = strcat('Color',{' '},num2str(row));
myCellArray{row, 2} = strcat('#',num2str(rgbconv([P(row,1)/den P(row,2)/den P(row,3)/den])));
myCellArray{row,3} ='RGB';
end
%Write data to excel File
varNames = {'Color Name','Hex Code','RGB'};
data = cell2table(myCellArray,'VariableNames',varNames);
writetable(data,filename)
display(data)
%Read data from excel File to table
tdata = readtable(filename,'PreserveVariableNames',1);
display(tdata)
tdata= tdata(:,:);
manualTable = uitable(clTab2,'Units','normalized','Position',[.0 .1 1 .6],'Data',tdata);
Error using uitable
Functionality not supported with figures created with the figure function.

回答 (1 件)

Bruno Luong
Bruno Luong 2021 年 9 月 8 日
編集済み: Bruno Luong 2021 年 9 月 8 日
Sorry there is no workaround.
  3 件のコメント
Bruno Luong
Bruno Luong 2021 年 9 月 8 日
No
Stephani Kanga
Stephani Kanga 2021 年 9 月 8 日
Ok, thank you.

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

カテゴリ

Help Center および File ExchangeMigrate GUIDE Apps についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by