Date: Aug 10, 2010 1:23 PM
Author: teki
Subject: Re: Undefined function or variable - for no reason...

Hi,

I am facing the same problem today.

I try to run the .m file in my current directory and Matlab would give the message - "Undefined function or variable". I add the current path and still it does not recognize any .m file in the current directory.

Moreover, any new .m file is not running at all, while some of the old .m files I executed previously are working fine.

Any help is most appreciated!

Many thanks,
Sundeep

"Steven Lord" <slord@mathworks.com> wrote in message <hute1f$ifa$1@fred.mathworks.com>...
>
> "Theophane " <theo.weber@hotmail.com> wrote in message
> news:huspi6$6ko$1@fred.mathworks.com...

> > Matlab has gone mad! It won't accept any declaration other than
> > predeclared matlab functions (say, fft). Almost any other function call
> > returns 'Undefined function or method bla bla'.
> >
> > I know you'll think that I don't have the path defined correctly, or that
> > my function is not defined properly, but this is not the case. I am trying
> > to call functions or script located in the directory i am currently
> > browsing.
> >
> > Tab autocompletes their name when I start typing the first few letters.
> > But as soon as I press enter, matlab gets confused. I have been using
> > matlab for years, never encountered this problem.
> >
> > Even weirder, I can copy those files in a different folder, and sometimes,
> > just sometimes, they will work. For a bit. Before becoming un-callable
> > again.
> > This does not concern all the files I am using, just some. they can be on
> > a different drive, too.
> >
> > Does anyone have any clue what is going on?

>
> Send a listing of the names of the files in that directory to Technical
> Support so they can investigate what's going on.
>
> --
> Steve Lord
> slord@mathworks.com
> comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ
> To contact Technical Support use the Contact Us link on
> http://www.mathworks.com
>