Loading .mat file content into base workspace by calling load function within a gui callback function
이전 댓글 표시
I can't load the data I want into base workspace (although they appear perfectly in the command window) for furthe use. I use Load function within a gui callback function and I think this what makes loading process difficult. To be more specific, I need to load variables tmp and specs into base workspace, any ideas? Please see the attached screenshot for more details. Many thanks
댓글 수: 4
Adam
2016년 3월 22일
Why do you need variables in the base workspace if you are using a GUI? Or why are you using a GUI if you are working in the base workspace?
Functions have their own workspace, this can be shared between GUI callbacks in different ways.
If you really want to do what you are asking then
doc assignin
should help, though it is not an approach I recommend and points towards bad design in general.
Mus'ab Ahmad
2016년 3월 22일
Stephen23
2016년 3월 22일
"there must be better solution."
There is!
Pass variables properly, exactly as the documentation recommends:
Mus'ab Ahmad
2016년 3월 23일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Workspace Variables and MAT Files에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!