필터 지우기
필터 지우기

how to display texts in gui itself?

조회 수: 2 (최근 30일)
Sivakumaran Chandrasekaran
Sivakumaran Chandrasekaran 2013년 4월 8일
For my present code, output (abnormal (or) normal) will appear in command window only. I need to display it in gui itself... how to write it?

답변 (1개)

Yao Li
Yao Li 2013년 4월 8일
Add an Edit Text (eg. edit1)
function edit1_CreateFcn(hObject, eventdata, handles)
% hObject handle to edit1 (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles empty - handles not created until after all CreateFcns called
% Hint: edit controls usually have a white background on Windows.
% See ISPC and COMPUTER.
if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor'))
set(hObject,'BackgroundColor','white');
end
res=4;
set(hObject,'String',num2str(res))

카테고리

Help CenterFile Exchange에서 Annotations에 대해 자세히 알아보기

태그

제품

Community Treasure Hunt

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

Start Hunting!

Translated by