Invalid expression. When calling a function or indexing a variable, use parentheses. Otherwise, check for mismatched delimiters.

if ispc && isequal(get(hObject,'BackgroundColor')
Invalid expression. When calling a function or indexing a variable, use parentheses. Otherwise, check for mismatched delimiters.
get(0,'defaultUicontrolBackgroundColor'));
set(hObject,'BackgroundColor','white');
end

 採用された回答

When you open a door, you must then close it, else MATLAB will not be happy. Look carefully at the line in question. After all, MATLAB flagged it.
if ispc && isequal(get(hObject,'BackgroundColor')
Count the number of open parens. I see TWO of them.
Next, count the number of close parens. I see only ONE.
Finally, re-read the error message.

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で MATLAB Coder についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by