- The value is NaN, blank, or a complex number.
Clearing an edit field (numeric) and text area
6 次查看(过去 30 天)
显示 更早的评论
Hey guys,
Just a quick question about how to clear a numeric edit field. Ive tried using the following code to clear both a numeric edit feild and text area. This code doesnt work as an error pops up saying the 'Value' must be double scalar

Thanks :)
0 个评论
回答(1 个)
Cris LaPierre
2020-5-7
A numeric edit field cannot be blank. You can read more about the value properties of this component here.
MATLAB rejects the value if:
4 个评论
Cris LaPierre
2020-5-7
Ah, putting it in quotes makes it text, resulting in the error message you were seeing.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Structures 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!