"Arnab Ghosh" <email@example.com> wrote in message news:firstname.lastname@example.org... > I have a GUI which through one of toolbar buttons, takes another function > output. The function takes two vector input and returns a matrix as > output. User selects the toolbar button, and then in the file browser > dialog box selects a function according to her choice. It seems to be > working fine, until I compiled the GUI into executable file. After file > selection, strange errors is popping up. It seems that the executable can > not access the function file. Can anyone please tell me what I am missing > here?
You're trying to specify a function to be run at runtime and that function was not necessarily present when the GUI was compiled? That will not work. A compiled application can only access functions, scripts, and classes that were compiled into the application. You can't "add in" new functions/scripts/classes at runtime.
If you're trying to specify a function that WAS present when the GUI was compiled but is called only via FEVAL, EVAL, etc. then you need to tell MATLAB Compiler at compiled-time that it should include those functions in the application. See "Does the application begin execution and result in MATLAB or other errors?" on this documentation page.