필터 지우기
필터 지우기

Remove/Refresh all Fields

조회 수: 2 (최근 30일)
Dc215905
Dc215905 2020년 3월 16일
댓글: Dc215905 2020년 3월 17일
I've created a data analysis GUI where you can load in several datasets and run a numbe of preprocessing steps.
I'd like to include a refresh buttton that clears all of fields. I've used :
handle = rmfield(handles, 'uniqueField'),
but is there away to just:
handles = rmfield(handles, 'ALL')
Thanks

채택된 답변

Rik
Rik 2020년 3월 16일
Yes, although you should consider changing your data structure.
handles = struct;%will do what you ask
You should store all data in just a single field of the guidata struct. That way you can simply overwrite that single field with an empty struct.

추가 답변 (0개)

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by