Demonstrates how to redirect the output of a MATLAB-Compiler generated application to a log file.
thanks for this submission.
It works just fine for a command line application. However for a GUI application I can't suppress the command window compiling with log.c.
Can you please advice what needs to be changed in log.c (and possibly also in the mbuild-command?) to suppress the command window for Windows GUI applications?
The MATLAB Compiler generates libmsgfcn.h and libmsgfcn.lib. And yes, this will be a topic for a future blog post (to be published in Sept. or Oct. 2011, most likely).
This looks like a very interesting way to redirect the output streams in deployed applications, however, the ZIP file available for download does not appear to include the libmsgfcn.lib and libmsgfcn.h files. Could you advise me where to locate these files please.
Your example here seems to relate to output redirection when calling the shared libary from a standalone C application - is it possible to achieve a similar effect when calling the shared library from a .NET applicatation? I am are running in to problems when the compiled Matlab code tries to output text to the console (i.e. standard output stream) which causes the .NET application to throw an exception.
The only advise I have been able to find online for redirecting streams is to use evalc() in the compiled code, however, this is not very elegant.
Do you have any plans to elaborate on this important subject in one of your excellent blog posts?
Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.