Path: news.mathworks.com!newsfeed-00.mathworks.com!newsfeed2.dallas1.level3.net!news.level3.com!postnews.google.com!y10g2000prc.googlegroups.com!not-for-mail
From: Nathan <ngreco32@gmail.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: gui .m file referencing functions in older version instead of own
Date: Sat, 20 Jun 2009 10:54:15 -0700 (PDT)
Organization: http://groups.google.com
Lines: 25
Message-ID: <0ad1b602-3b0b-4d4a-b819-d30be043ae1b@y10g2000prc.googlegroups.com>
References: <h1ig0e$s6k$1@fred.mathworks.com>
NNTP-Posting-Host: 24.5.215.3
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
X-Trace: posting.google.com 1245520455 21578 127.0.0.1 (20 Jun 2009 17:54:15 GMT)
X-Complaints-To: groups-abuse@google.com
NNTP-Posting-Date: Sat, 20 Jun 2009 17:54:15 +0000 (UTC)
Complaints-To: groups-abuse@google.com
Injection-Info: y10g2000prc.googlegroups.com; posting-host=24.5.215.3; 
	posting-account=_KeVcAoAAAB7j3xn35ujaQ0BoQhuzwJP
User-Agent: G2/1.0
X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.11) 
	Gecko/2009060215 Firefox/3.0.11,gzip(gfe),gzip(gfe)
Xref: news.mathworks.com comp.soft-sys.matlab:549163


On Jun 20, 4:09 am, "scott" <grenb...@yahoo.deletethis.com> wrote:
> I made a gui using guide (call it mygui with .m file mygui.m) and then revised it and called it mygui2 (with .m file mygui2.m).  However, when I run mygui2, instead of calling its own functions, it calls functions from mygui (which are called the same thing).  For some reason, it is not giving its own namespace priority.  I don't have much experience putting multiple functions in a single .m file, so I don't know whether this is just what matlab does, but it would seem intuitive to give the functions in one's own .m file priority.
>
> Other than the easy but annoying fix of naming all the functions differently (although I haven't tried this to make sure it would work), is there anything else to be done?
> Thanks,
> Scott
>
> version: 2007b
> os: win

What you would want to do instead is save the .fig file as mygui2, it
will automatically name the new .m file accordingly and fix and
linking issues.
This has happened to me too, and that's what solved it.
Good luck
-Nathan