If and elseif is not collapsable

조회 수: 4 (최근 30일)
Ibrahim A
Ibrahim A 2021년 5월 19일
댓글: Ibrahim A 2021년 5월 20일
I have a multiple elseif statment, but somehow I cannot collapse the indivudual elseif statment. Is there a way to this?

채택된 답변

DGM
DGM 2021년 5월 19일
편집: DGM 2021년 5월 19일
Code folding options are in preferences under Editor>Code Folding; however, (as far as I know) that only allows the entire if/else structure to be folded. Individual cases within it can't. At least that's the way it is in R2015b and R2019b. Anyone is free to prove me wrong on that.
EDIT: It may be of interest to point out that while individual cases within an if-else structure aren't foldable, cases within a switch-case structure are.
  댓글 수: 1
Ibrahim A
Ibrahim A 2021년 5월 20일
Thank you very much, I can use switch case instead :)

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

추가 답변 (0개)

카테고리

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

태그

Community Treasure Hunt

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

Start Hunting!

Translated by