assign variable output to a column in GUI table
Mostrar comentarios más antiguos
How can I assign the values stored in a variable (x) to a column of a table in GUI. please help
1 comentario
Geoff Hayes
el 16 de Abr. de 2018
amna - are you creating your GUI with GUIDE, App Designer, or programmatically? Please clarify.
If using GUIDE, then you could do something like the following (I'm assuming that you have some sort of callback that performs an action that results in you wanting to update your table)
tableData = get(handles.uitable1, 'Data');
tableData(:,2) = x;
set(handles.uitable1, 'Data', tableData);
The assumptions are that your UI table is named uitable1 and that the number of rows in x is identical to the number of rows in the table (if not, then you can specify which rows of a certain column in the table you need to replace). For the purposes of this example, I'm replacing all of column 2 with x.
Respuestas (0)
Categorías
Más información sobre Structures en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!