how to change the edit box color in gui?

2 ビュー (過去 30 日間)
Fatma Al-Sharji
Fatma Al-Sharji 2015 年 4 月 23 日
i want to change the background color of my edit box after i clicked my push button.
what i did was
a=get(handles.edit1,'string');
if a=='2';
set(handles.edit1,'BackgroundColor','red')
end
%these codes are under pushbutton1 callback function.
but still it doesnt change anything to my edit1 background.
what is wrong with it?
the command window doesnt say anything about any errors or mistakes111

回答 (0 件)

カテゴリ

Help Center および File ExchangeInteractive Control and Callbacks についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by