How can one specify a cell array or string array when your message has multiple lines of text?
显示 更早的评论
If the title is confusing, then you're in the same place as me. I am attempting to create a uiconfirm figure in App Designer.
I have consulted the uiconfirm documentation page, and am having trouble with the message input arguement. The documentations says under message,
"Message to display, specified as a character vector, cell array of character vectors, or string array. Specify a cell array or string array when your message has multiple lines of text. Each element in the array corresponds to a different line of text."
My interpretation of this is that the message can indeed be a cell or string array, thus allowing it to display multiple lines. I cannot find any clarification on how one might specify that the arguement would be an array. I am attempting to pass a 1x14 cell array to the message arguement but MATLAB seems content with giving me the following error.
Error using uiconfirm (line 63)
'Message' must be a char array, string array or a cell array of character vectors.
Error in app1/UserInputConfirmationDialog (line 266)
uiconfirm(app.UIFigure,message,title, ...
Error in app1/StartButtonParamsPushed (line 350)
UserInputConfirmationDialog(app);
Error using matlab.ui.control.internal.controller.ComponentController/executeUserCallback (line 309)
Error while evaluating Button PrivateButtonPushedFcn.
I'm still somewhat new to MATLAB and I can understand that I may have interpreted the documentation wrong. Hopefully someone can offer me some clarification.
1 个评论
Adam Danz
2019-5-14
If my examples below do not help, please show us what your input variables look like.
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Characters and Strings 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
