Hello,
So I used find_system to get all subsystem name, one of them is EmbeddedMATLAB Function.
it occupies only one cell, but if I put it into listdlg it becomes 2 lines of :
Embedded
MATLAB Function
how to make it so that it is also showing as one line on the listdlg?

 採用された回答

Rik
Rik 2019 年 9 月 26 日

0 投票

There is probably a char 10 or 13 in there. On newer releases it will show a return symbol in the variable editor, but I don't know if that is the case for R2016b.
You can remove them with the line below.
str=strrep(str,{char(10),char(13)},'');%untested
If that errors you may need to call strrep twice.
str=strrep(strrep(str,char(10),''),char(13),'');

1 件のコメント

Muhammad Halindra Prakoso
Muhammad Halindra Prakoso 2019 年 10 月 9 日
thank you!
the first code returns 2 cells so I call strrep twice

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

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeInteractive Control and Callbacks についてさらに検索

製品

リリース

R2016b

Community Treasure Hunt

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

Start Hunting!

Translated by