Thread Subject: Unable to Save, Print or Open from figure

Subject: Unable to Save, Print or Open from figure

From: Brendan Tracey

Date: 8 May, 2009 08:35:02

Message: 1 of 5

Thanks in advance for your help

I am unable to save, print or open from the figure GUI. From the error messages, it looks like something is going wrong with a pointer to the figure. I don't know what caused the error to start happening, and I'm not really sure how to fix it. I am running Matlab 7.4.0.

Thank you very much

 Here are the exact errors.

Save :
Error: File: ismember.m Line: 1 Column: 3
Expression or statement is incomplete or incorrect.

Error in ==> AbstractFileDialog.AbstractFileDialog>AbstractFileDialog.set.InitialFileName at 68
            if any(ismember({'.', '..'}, iFile))

Error in ==> AbstractFileDialog.AbstractFileDialog>AbstractFileDialog.initialize at 238
            obj.InitialFileName = '';

Error in ==> UiFileSaveDialog.UiFileSaveDialog>UiFileSaveDialog.initialize at 68
            initialize@AbstractFileDialog(obj);

Error in ==> UiFileSaveDialog.UiFileSaveDialog>UiFileSaveDialog.UiFileSaveDialog at 6
            initialize(obj);

Error in ==> uitools\private\uigetputfile_helper at 38
        ufd = UiFileSaveDialog();

Error in ==> uiputfile at 110
    [filename, pathname, filterindex] = uigetputfile_helper(1, varargin{:});

Error in ==> filemenufcn>localSaveExport at 284
    [newfile, newpath, typevalue] = uiputfile(filter, 'Save As',filename);

Error in ==> filemenufcn at 55
        localSaveExport(hfig)

??? Error using ==> filemenufcn(gcbf,'FileSaveAs')
Error: File: ismember.m Line: 1 Column: 3
Expression or statement is incomplete or incorrect.

??? Error while evaluating uimenu Callback



Open:

Error: File: ismember.m Line: 1 Column: 3
Expression or statement is incomplete or incorrect.

Error in ==> AbstractFileDialog.AbstractFileDialog>AbstractFileDialog.set.InitialFileName at 68
            if any(ismember({'.', '..'}, iFile))

Error in ==> AbstractFileDialog.AbstractFileDialog>AbstractFileDialog.initialize at 238
            obj.InitialFileName = '';

Error in ==> UiFileOpenDialog.UiFileOpenDialog>UiFileOpenDialog.initialize at 120
            initialize@AbstractFileDialog(obj);

Error in ==> UiFileOpenDialog.UiFileOpenDialog>UiFileOpenDialog.UiFileOpenDialog at 11
            initialize(obj);

Error in ==> uitools\private\uigetputfile_helper at 35
        ufd = UiFileOpenDialog();

Error in ==> uigetfile at 125
    [filename, pathname, filterindex] = uigetputfile_helper(0, varargin{:});

Error in ==> uiopen at 161
    [fn,pn] = uigetfile(filterList,'Open');

Error in ==> filemenufcn at 49
        uiopen figure

??? Error using ==> filemenufcn(gcbf,'FileOpen')
Error: File: ismember.m Line: 1 Column: 3
Expression or statement is incomplete or incorrect.

??? Error while evaluating uimenu Callback



Print

??? Error using ==> print at 307
Error: File: ismember.m Line: 1 Column: 3
Expression or statement is incomplete or incorrect.

Error in ==> printdlg at 84
  eval(pstr)

??? Error using ==> printdlg(gcbf)
Error using ==> print at 307
Error: File: ismember.m Line: 1 Column: 3
Expression or statement is incomplete or incorrect.

??? Error while evaluating uimenu Callback

Print:

Subject: Unable to Save, Print or Open from figure

From: Steven Lord

Date: 8 May, 2009 13:40:35

Message: 2 of 5


"Brendan Tracey" <hockeybdt@hotmail.com> wrote in message
news:gu0qrm$mga$1@fred.mathworks.com...
> Thanks in advance for your help
>
> I am unable to save, print or open from the figure GUI. From the error
> messages, it looks like something is going wrong with a pointer to the
> figure. I don't know what caused the error to start happening, and I'm not
> really sure how to fix it. I am running Matlab 7.4.0.
>
> Thank you very much
>
> Here are the exact errors.
>
> Save :
> Error: File: ismember.m Line: 1 Column: 3
> Expression or statement is incomplete or incorrect.

Take a look at line 1 of the ismember.m file. Does it look correct -- is it
a normal function declaration line?

Are you using an ismember.m file written by someone else and if so, was it
written with a valid function declaration line? [You can check which copy
of ISMEMBER you're using with "which -all ismember".]

Did you for some reason add the toolbox/matlab/ops/ja directory to the path?
If so, remove that directory from your path.

Did you accidentally edit the ismember.m file and put a line break or
unexpected character on column 3 of line 1 of the file?

--
Steve Lord
slord@mathworks.com

Subject: Unable to Save, Print or Open from figure

From: Jared

Date: 12 Mar, 2010 14:27:05

Message: 3 of 5

"Steven Lord" <slord@mathworks.com> wrote in message <gu1co4$oc0$1@fred.mathworks.com>...
>
> "Brendan Tracey" <hockeybdt@hotmail.com> wrote in message
> news:gu0qrm$mga$1@fred.mathworks.com...
> > Thanks in advance for your help
> >
> > I am unable to save, print or open from the figure GUI. From the error
> > messages, it looks like something is going wrong with a pointer to the
> > figure. I don't know what caused the error to start happening, and I'm not
> > really sure how to fix it. I am running Matlab 7.4.0.
> >
> > Thank you very much
> >
> > Here are the exact errors.
> >
> > Save :
> > Error: File: ismember.m Line: 1 Column: 3
> > Expression or statement is incomplete or incorrect.
>
> Take a look at line 1 of the ismember.m file. Does it look correct -- is it
> a normal function declaration line?
>
> Are you using an ismember.m file written by someone else and if so, was it
> written with a valid function declaration line? [You can check which copy
> of ISMEMBER you're using with "which -all ismember".]
>
> Did you for some reason add the toolbox/matlab/ops/ja directory to the path?
> If so, remove that directory from your path.
>
> Did you accidentally edit the ismember.m file and put a line break or
> unexpected character on column 3 of line 1 of the file?
>
> --
> Steve Lord
> slord@mathworks.com
>

Was this ever resolved?
I have a different issue, I am using the Builder for Java.
I can build a m-file and it produces a jar file and I can call it from my Java program.
The figure displays correctly but some of the menu options don't work. I get errors such as,

??? Attempt to reference field of non-structure array.
??? Error while evaluating uimenu Callback

Any thoughts?

Subject: Unable to Save, Print or Open from figure

From: Jared

Date: 12 Mar, 2010 14:28:03

Message: 4 of 5

"Steven Lord" <slord@mathworks.com> wrote in message <gu1co4$oc0$1@fred.mathworks.com>...
>
> "Brendan Tracey" <hockeybdt@hotmail.com> wrote in message
> news:gu0qrm$mga$1@fred.mathworks.com...
> > Thanks in advance for your help
> >
> > I am unable to save, print or open from the figure GUI. From the error
> > messages, it looks like something is going wrong with a pointer to the
> > figure. I don't know what caused the error to start happening, and I'm not
> > really sure how to fix it. I am running Matlab 7.4.0.
> >
> > Thank you very much
> >
> > Here are the exact errors.
> >
> > Save :
> > Error: File: ismember.m Line: 1 Column: 3
> > Expression or statement is incomplete or incorrect.
>
> Take a look at line 1 of the ismember.m file. Does it look correct -- is it
> a normal function declaration line?
>
> Are you using an ismember.m file written by someone else and if so, was it
> written with a valid function declaration line? [You can check which copy
> of ISMEMBER you're using with "which -all ismember".]
>
> Did you for some reason add the toolbox/matlab/ops/ja directory to the path?
> If so, remove that directory from your path.
>
> Did you accidentally edit the ismember.m file and put a line break or
> unexpected character on column 3 of line 1 of the file?
>
> --
> Steve Lord
> slord@mathworks.com
>

Was this ever resolved?
I have a different issue, I am using the Builder for Java.
I can build a m-file and it produces a jar file and I can call it from my Java program.
The figure displays correctly but some of the menu options don't work. I get errors such as,

??? Attempt to reference field of non-structure array.
??? Error while evaluating uimenu Callback

Any thoughts?

Subject: Unable to Save, Print or Open from figure

From: Steven Lord

Date: 12 Mar, 2010 14:37:12

Message: 5 of 5


"Jared " <jared.olbricht@lmco.com> wrote in message
news:hndivp$9bh$1@fred.mathworks.com...

*snip*

> Was this ever resolved? I have a different issue, I am using the Builder
> for Java.

When you post a new issue, please use a new thread. They're cheap and easy
to create.

> I can build a m-file and it produces a jar file and I can call it from my
> Java program.
> The figure displays correctly but some of the menu options don't work. I
> get errors such as,
>
> ??? Attempt to reference field of non-structure array.
> ??? Error while evaluating uimenu Callback
>
> Any thoughts?

My first suspicion, particularly if the GUI works inside MATLAB, is that
you're missing some callbacks. Take a look at the "Fixing Callback
Problems: Missing Functions" and "Finding Missing Functions in an MATLAB
File" sections of the MATLAB Compiler documentation's Troubleshooting
chapter:

http://www.mathworks.com/access/helpdesk/help/toolbox/compiler/br2cqa0-2.html#br2cqa0-5

Also make sure you're not trying to use a function that's not supported for
use with MATLAB Compiler (which MATLAB Builder for Java uses.) I believe
that information will be included in the log files created when you compiled
your application.

If that doesn't work, I think you should probably contact Technical Support,
as it would be difficult to troubleshoot this issue further without seeing
your code and how it was compiled, and that's a bit much to include in a
newsgroup posting.

--
Steve Lord
slord@mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ

Tags for this Thread

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

rssFeed for this Thread

Contact us at files@mathworks.com