How do you display a certain string as static text on a GUI by code?

Does anyone know how to post a string within static text to a GUI? For example, we want the string to either say "PASS" or "FAIL" on the GUI when comparing two pictures to see if they are the same. If the pictures are the same the string will say "PASS", but if the pictures are different it will say "FAIL" on the GUI. We have been using set(handles.text7, 'String', 'Pass'), but it is not giving us any results. Can someone please help! Thanks!

回答 (1 件)

Azzi Abdelmalek
Azzi Abdelmalek 2012 年 11 月 13 日
編集済み: Azzi Abdelmalek 2012 年 11 月 13 日

0 投票

set(handles.text7, 'String', 'Pass')
is correct , click on your static text object and check if the name of your tag is text7 or maybe your test is not correct

カテゴリ

ヘルプ センター および File Exchange で Language Support についてさらに検索

製品

タグ

質問済み:

Bob
2012 年 11 月 13 日

Community Treasure Hunt

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

Start Hunting!

Translated by