필터 지우기
필터 지우기

Assign value to slider in GUI from other M-files

조회 수: 1 (최근 30일)
Cheng Yoong
Cheng Yoong 2011년 11월 13일
I have a GUI that contain two sliders. Then I created a seperate M-file roughly like this:
function [theta1,theta2] = inverse(positionX,positionY)
.
.
.
theta1=..
theta2=..
how can i assign the theta1 and theta2 to the respective sliders?

답변 (1개)

Walter Roberson
Walter Roberson 2011년 11월 13일
You set() the Value property of the slider handle to the new value. Depending on how you use the function, this might require passing the slider handles in to the function (or using findobj() to fetch the handles of the sliders.)
  댓글 수: 1
Cheng Yoong
Cheng Yoong 2011년 11월 13일
Can you give me example?I'm still new to Matlab.

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

카테고리

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

Community Treasure Hunt

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

Start Hunting!

Translated by