Re: PostMessage() Error
I think it's good advice. What the OP is trying to do is like feeding a cow
through back orifice. It might be possible, of course, but only if you put a
catheter all the way to the stomach.
"Ben Voigt" <rbv@nospam.nospam> wrote in message
news:eNEapdnWHHA.5108@TK2MSFTNGP06.phx.gbl...
The correct solution, and if you get this to work all wgnuplot users will
probably love you for it, is to get rid of IPC entirely. There's no
reason that pgnuplot should need to open wgnuplot and start simulating GUI
input in order to process a file from stdin. To do this right, would
entail splitting wgnuplot into two pieces, wgnuplot.exe which has the
interactive GUI, and a dll (gpshared.dll?) that has all the plot layout,
etc features, that need to be accessible from pgnuplot. Then pgnuplot
would be changed to invoke this new API instead of the hack it currently
is. Note that you won't be able to perfectly separate GUI processing from
the plot code in the dll, because of the "windows" output driver. So
you'd have to have a function for setting the HWND of the plot window or
something to that effect, and then disable the "windows" output driver if
it hasn't been properly associated to a window. That would also open up
possibilities in integrating gnuplot into other apps using its DLL.