TracebackQQ options

TracebackQQ options

As part of my debugging set-up I have an error handling routines that primarily handles errors from the windows sdk via the getlasterror function. I do different things at different times, sometimes I just log, sometimes I set breakpoints etc. Some errors are not a big deal (fix later) and some are (fix now). I embedded a call to the Fortran runtime TracebackQQ function to get the stack so I can report where we are in the program without having to initiate my own tracing scheme.

The default behaviour of  TracebackQQ is to sound a gong and pop a message box with the info. which is quite disruptive and not very flexible, Is there any other option, there doesn't appear to be? Getting a text buffer with the info would be ideal. Is there any other lower level function that I can call that would give the information?



4 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

There is not a lower-level routine, as we implement this ourselves, but you can redirect the output of TRACEBACKQQ with the FOR_DIAGNOSTIC_LOG_FILE environment variable. The message box appears only for non-console applications.

Retired 12/31/2016

Thanks Steve I just had a read on that. Is directing the output to a file the only option? For example my Windows application attaches to a custom console Window (using winapi  AttachConsole)  where I send some output?

Also, can I set FOR_DIAGNOSTIC_LOG_FILE and FOR_DISABLE_DIAGNOSTIC_DISPLAY programmatically or is that only by setting the environment (which I could do programmatically).

Can a log a feature request for an option parameter on TracebackQQ to return the stack trace as a text buffer? For now I can mackle something to pipe to a file and read back but that isn't nice!

As an aside AttachConsole is missing from USE kernel32 I had to provide my own interface. It should be their really as in addition to all the other console functions that are. By creating a console with the winapi you can set a wider range of attributes.

An as an aside, aside when you "disable rich-text" on a post in the hope of getting plain text to eliminate  misformated cut n paste stuff (like the above) it kindly inserts all the HTML formatting as text as well!


You can set the variables using SETENVQQ. I can't think of another option offhand. I will enter a feature request for you.

Retired 12/31/2016

Leave a Comment

Please sign in to add a comment. Not a member? Join today