I have a program that crashes on startup, the error message appears in the console,
but the console disappears in 1 second so I cant read it.

How do I redirect debug messages to the Lazarus IDE?