console application Vs Stand alone application

10 visualizaciones (últimos 30 días)
yuri tupizin
yuri tupizin el 19 de Abr. de 2015
Comentada: Image Analyst el 2 de Mzo. de 2020
Hi , First of all I would like to understand the difference between the two , and second of all I would like to know if I can create a "console application" via code , I know I can create Stand alone application using the mcc function .
Thanks
Yuri

Respuestas (1)

Image Analyst
Image Analyst el 19 de Abr. de 2015
You need the MATLAB Compiler product to compile your m-file into a standalone program. See the FAQ: http://matlab.wikia.com/wiki/FAQ#MATLAB_Compiler_Toolbox
Your standalone program can either be a console application, like everything happens in the console (DOS) window, or a GUI application. If all your user interactions took place in the command window, when running your m-file in the MATLAB environment, then it will be a console application. If you had a user interface, like you built your app using GUIDE or any of the other functions that popped up a dialog box or figure, then it will be a GUI application. And of course it can be a mixture of both, though that would be confusing to the user if they had to input in different places. I always do GUI applications though I will put status information into the console window, particularly when the app is launching and I'm in the OpeningFcn function, since that's the only way (well, at least a good, or easy, way) to see what functions you're in and how far along you got before it crashed. Again, read the FAQ.
  3 comentarios
Vishal Chouhan
Vishal Chouhan el 2 de Mzo. de 2020
Hey. Could you please share the reference.how it can be mixture of console and gui such that I can track my logg and other stuff as display output as you said
Image Analyst
Image Analyst el 2 de Mzo. de 2020
Just use console things in your GUI when you want to, like fprintf() or input(). However I think having user input on both the GUI and console window would be very aggravating for the user. Using fprintf() to print status/debugging info would be fine though, and I do that. Sometimes you just want to print stuff out there to help you should the user ever come back to you with a problem and if they can include a screenshot of the console window, it could be helpful figuring out what went wrong when they ran your program.

Iniciar sesión para comentar.

Categorías

Más información sobre Startup and Shutdown en Help Center y File Exchange.

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by