Why my Windows Standalone Application doesn't work out as its original file?
    3 views (last 30 days)
  
       Show older comments
    
Hello,
I've created an executable file from a .m file using the Deployment Tool, but the generated file doesn't work properly. It doesn't do the same thing as the .m file running directly from Matlab. I just want it to open a Simulink file (.mdl or .slx). Here follows the code:
%%%%%%%%%%%%%%%%%%
global ModelName
[filename, pathname] = uigetfile({'*.slx;*.mdl', 'Modelo (*.mdl, *.slx)'});
[pathstr, name, ext] = fileparts(filename);
modelo = strcat(pathname,filename);
open_system(modelo);
ModelName = name;
set_param(ModelName,'BlockReduction','off');
%%%%%%%%%%%%%%%%%%%%
Why this happens? Does anybody know what I can do?
Thanks!
0 Comments
Accepted Answer
  Harsheel
    
 on 20 Sep 2013
        open_system is an unsupported function which cannot be compiled. A list of supported/unsupported functions with various toolboxes can be found here:
open_system is listed here:
3 Comments
More Answers (1)
  Image Analyst
      
      
 on 18 Sep 2013
        Does it run at all? Did you try the things on the FAQ: http://matlab.wikia.com/wiki/FAQ#My_standalone_executable_won.27t_run_on_the_target_computer._What_can_I_try.3F
3 Comments
  Image Analyst
      
      
 on 18 Sep 2013
				
      Edited: Image Analyst
      
      
 on 18 Sep 2013
  
			So it launches, it just doesn't do what you expect. Well I don't have Simulink (which I just added to the product list tag) so I can't help further.
See Also
Categories
				Find more on Simulink Coder in Help Center and File Exchange
			
	Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


