02-26-2019, 02:23 PM
As a rule I don't have time to dig into general Delphi issues but I can try to help. If you want to post the pipe handling code as text in a message I can give it a glance though.
If its a simple console you are calling out too, there are tons of code snippets out there. I can even send you one we use for 17 (its used from within the main thread of the IDE, but it should work fine in a thread)
The "normal" app in which it works, is it a console or VCL forms app? There are a few possibilities that are most likely:
1) IntraWeb is threaded because its a server. So your code will be running in a secondary thread, not the main thread.
2) Because you are running in threads, there is no main message queue. If your code depends on this, this will cause issues. Most piping code should not need the message queue though.
3) Permissions - This can affect both the hosted app, but also inheritance of handles which are used for pipes.
If its a simple console you are calling out too, there are tons of code snippets out there. I can even send you one we use for 17 (its used from within the main thread of the IDE, but it should work fine in a thread)
The "normal" app in which it works, is it a console or VCL forms app? There are a few possibilities that are most likely:
1) IntraWeb is threaded because its a server. So your code will be running in a secondary thread, not the main thread.
2) Because you are running in threads, there is no main message queue. If your code depends on this, this will cause issues. Most piping code should not need the message queue though.
3) Permissions - This can affect both the hosted app, but also inheritance of handles which are used for pipes.

