In the popupmenu how to show the serial number of the choice?

조회 수: 1 (최근 30일)
Csaba
Csaba 2018년 10월 12일
I have a list (string cell array) where I store the description of an object. When I present it in the popupmenu it would be nice to have the serial number of the choice as well. I do not want to incorporate serials into the list because it is possible to change the order of the objects, so before I put the list on the popupmenu I would like to put the actual serial numbers there.
Please help, how to do this, to add simply a number to a string cell array. Some elements of the array might also be empty, therefore in AA=string(list) command I get "Error using string Conversion from cell failed. Element 19 must be convertible to a string scalar."
Here element 19 is empty.
Thanks.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Data Types에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by