필터 지우기
필터 지우기

carry value of variable in other function

조회 수: 2 (최근 30일)
777
777 2012년 3월 15일
i m creating a gui where pushbutton callback has the code to take a .wav input in z1.
Fs = 44100; % Sampling Freq (Hz)
Duration = 1; % Duration (sec)
z1 = wavrecord(Duration*Fs,Fs);
now i want z1 to contain the values in other function also.what should i do.plss help
thanks and regards

채택된 답변

Sean de Wolski
Sean de Wolski 2012년 3월 15일

추가 답변 (1개)

777
777 2012년 3월 15일
i found it, declare z1 as global in each function global z1 :)

카테고리

Help CenterFile Exchange에서 Scope Variables and Generate Names에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by