App Designer has suddendly stopped recognising the string() function.

1 回表示 (過去 30 日間)
Alan Norman
Alan Norman 2022 年 9 月 14 日
回答済み: Alan Norman 2022 年 9 月 14 日
Previously stable parts of code in my script have stopped working because Matlab seems to have forgotten what string() is.
Autocomplete still suggests it when typing but the error presists even when the I use the autocomplete. Its not isolated to this line. If commented out the next string() throws the error.
I've restarted Matlab and the the PC. No joy.
String() does work in new scripts in both Matlab and the app designer.
Does anyone know whats going on?
  2 件のコメント
Ankit
Ankit 2022 年 9 月 14 日
which MATLAB Version are you using?
Alan Norman
Alan Norman 2022 年 9 月 14 日
Hi Ankit
Its R2022a Update 4(9.12.0.2009381)
64-bit

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

採用された回答

Alan Norman
Alan Norman 2022 年 9 月 14 日
**Update
So retracing my steps and mashing buttons, I believe i've found the cause.
I was try to populate a table from filedata and encoutered this error:
Foolishly I tried to cast the cell as a string() (Mechanical engineer by trade. I'm no expert)
When this casting attempt is removed the script returns to normal behaviour.
I hope this helps anyone who makes the same mistake.

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeData Type Identification についてさらに検索

製品


リリース

R2022a

Community Treasure Hunt

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

Start Hunting!

Translated by