Path: news.mathworks.com!not-for-mail
From: "Bruno Luong" <b.luong@fogale.findmycountry>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Function questions
Date: Mon, 11 May 2009 12:04:02 +0000 (UTC)
Organization: FOGALE nanotech
Lines: 26
Message-ID: <gu947i$khp$1@fred.mathworks.com>
References: <gu3a8b$pet$1@fred.mathworks.com> <gu3c4a$ob1$1@fred.mathworks.com> <MPG.2471dc3ebd35e04898999e@news.mathworks.com>
Reply-To: "Bruno Luong" <b.luong@fogale.findmycountry>
NNTP-Posting-Host: webapp-03-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1242043442 21049 172.30.248.38 (11 May 2009 12:04:02 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Mon, 11 May 2009 12:04:02 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 390839
Xref: news.mathworks.com comp.soft-sys.matlab:538968


Loren Shure <loren@mathworks.com> wrote in message <MPG.2471dc3ebd35e04898999e@news.mathworks.com>...
> In article <gu3c4a$ob1$1@fred.mathworks.com>, 
> b.luong@fogale.findmycountry says...
> > I keep this message for copy and past now and then:
> > 
> > Functions in GUI, like any other functions, have their own private workspace. They are not shared, and they are clear when the (nested) function ends.
> > 
> > To pass data among functions in Gui (it can be many guis), we have to use one of these options:
> > 
> > - GUIDATA
> > - SET/GETAPPDATA
> > - SET/GET on the field USERDATA of graphic handles of your GUI
> > - GLOBAL variables
> > - ASSIGNIN/EVALIN
> > 
> > The first ones are preferred methods. The two last are to be avoided.
> > 
> > Bruno 
> > 
> 
> Another option: use nested functions.
> 

And to pass the nested function handle around, use... the above of course

Bruno