Scripts can't be ran from button callback function??

조회 수: 1 (최근 30일)
Vadim Kachan
Vadim Kachan 2019년 6월 25일
댓글: Shameer Parmar 2019년 6월 27일
I am trying to press a button in my uicontrol that will callback a function that has "run xxxx" script. i get these errors
"Error while evaluating UIControl Callback."
  댓글 수: 2
Geoff Hayes
Geoff Hayes 2019년 6월 26일
Vadim - please copy and paste the full error message to this question. Also, please (at a minimum) show the callback function code so that we can see how this script is called.
Shameer Parmar
Shameer Parmar 2019년 6월 27일
You need to keep the script name inside the callback of your push button.
for example:
function pushbutton_Callback(hObject, eventdata, handles)
% hObject handle to msg_box (see GCBO)
% eventdata reserved - to be defined in a future version of MATLAB
% handles structure with handles and user data (see GUIDATA)
scriptName;

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

답변 (0개)

카테고리

Help CenterFile Exchange에서 Creating, Deleting, and Querying Graphics Objects에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by