0

I have a strange problem. I have a DUnit (Delphi Berlin) application, which I need to run as both GUI (on my development machine) and as a console app (on the build machine). I just copied the project file, renamed it. I have the usual :

 {$IFDEF CONSOLE_TESTRUNNER} 
 {$APPTYPE CONSOLE} 
 {$ENDIF}

And in one app I define the CONSOLE_TESTRUNNER conditional define and in the other I don't.

If I COMPILE the console application, it works as a console app. However, if I BUILD then it runs as a GUI app. (either in the GUI or at the command line) I have even tried removing the conditional define and explicitly setting it as {$APPTYPE CONSOLE}, to remove the conditional define out of the equation, but then the application just throws out an EInOutError I/O error 105. I guess it's trying to write to the output but failing. But why?

Steve
  • 6,382
  • 3
  • 41
  • 66

0 Answers0