gui and work space data sharing

1 vue (au cours des 30 derniers jours)
mohamed  al-asklany
mohamed al-asklany le 1 Juil 2012
how to attache data from work space to gui
  2 commentaires
Image Analyst
Image Analyst le 1 Juil 2012
You do know that there can be several workspaces, right? The base workspace, and then each function will have it's own local workspace.
mohamed  al-asklany
mohamed al-asklany le 1 Juil 2012
in simulinke model there is a "to workspace " assume its var is "sout" that i want this var "sout" identified by my gui program

Connectez-vous pour commenter.

Réponse acceptée

Luffy
Luffy le 6 Juil 2012
If you want to access data that is in base workspace in your gui functions,
use
v = evalin('base','name of variable u want to access');
% the variable's data is now stored in v.
If u want to save data of ur gui work space to base,use
assignin('base','name of variable u want to save','value of variable');

Plus de réponses (1)

Image Analyst
Image Analyst le 1 Juil 2012

Catégories

En savoir plus sur Variables dans Help Center et File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!

Translated by