필터 지우기
필터 지우기

how to write information into text boxes after GUI runs?

조회 수: 3 (최근 30일)
Andy
Andy 2011년 9월 7일
I am trying to write strings into a text box after the GUI starts running. i tried to use 'set' command, this is what i have
set(hObject, 'String', input_folder_name)
so the input_folder_name is a user inputted variable. i put this command line in the function created when i made the text box. can anyone tell me where i did wrong? Thanks

채택된 답변

Paulo Silva
Paulo Silva 2011년 9월 7일
Put the code inside the OpeningFcn
set(handles.text1, 'String', input_folder_name)
%text1 is the name of the textbox, you might need to change it
  댓글 수: 3
Paulo Silva
Paulo Silva 2011년 9월 8일
If the Ok is a pushbutton you just need to put the code inside that pushbutton callback
Andy
Andy 2011년 9월 8일
thank you so much, works like a charm

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Characters and Strings에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by