Why do I keep getting this error in my app designer?
조회 수: 4 (최근 30일)
이전 댓글 표시
I keep getting this error for a reason I am not sure off. I did train my folder, and I also made sure to input the correct name for the file within the code. What am I doing wrong? What does this error mean?
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1382289/image.png)
this is how the application looks like incase you might need it.
![](https://www.mathworks.com/matlabcentral/answers/uploaded_files/1382294/image.png)
답변 (1개)
Hiro Yoshino
2023년 5월 14일
편집: Hiro Yoshino
2023년 5월 14일
(1) This might be irrelevant ... You should change "ans" to something else since ans is already taken.
(2) strcmp, "string" is redundant.
myAns = "tulip";
if (strcmp(myAns,"tulip"))
app.Lamp.Color = "Pink";
elseif(strcmp(myAns,"sunflower"))
app.Lamp.Color = "Purple";
end
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Environment and Settings에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!