K
Kevin
First off, thanks to everyone in all groups for helping in the past.
I'm developing an application that is a mixture of two types of
executables: the "parent" file is written in C# and the "child" is written
in C++. I need to have some basic communication from the parent to the
child. I've looked into calling SendMessage and PostMessage, but I just
can't seem to find exactly what I'm looking for. And, unfortunately (as
usual), I need to have it yesterday. Here's what I'm trying to do.
The child app is started automatically upon a reboot of the device. Then,
the parent app is started. The child app is a specialized communication
system that, at this point, must be written in C++ (using eVC4). The parent
app (written in VCS2003) contains a button ([File Transfer]) that packages
the data in an XML file and adds it to a "queue". Then, it starts the comm
process (child app) if it isn't already running. All of this takes place
when the device is docked in a special cradle.
I need to be able to:
1) Get the "application" handle of the child, if it exists; or create the
process and get the handle (starting a child app seems to work with no
problem). The message functions require an HWND, which I believe is the
same as an IntPtr, but I'm unable to properly convert/use it.
2) Send a message to the child app to tell it to minimize or maximize. In
other words, I want it to "sleep" in the background until it's needed, and
then become visible.
Caveats:
I am doing this with Windows CE Pocket PC version 4.20. I'm also using CF
1.0. I also have OpenNETCF 1.4 available. I can't seem to get CF 2.0 to
work on this hardware/OS.
Can someone...anyone...explain to me how this is done, or point me to a
resource?
I'm developing an application that is a mixture of two types of
executables: the "parent" file is written in C# and the "child" is written
in C++. I need to have some basic communication from the parent to the
child. I've looked into calling SendMessage and PostMessage, but I just
can't seem to find exactly what I'm looking for. And, unfortunately (as
usual), I need to have it yesterday. Here's what I'm trying to do.
The child app is started automatically upon a reboot of the device. Then,
the parent app is started. The child app is a specialized communication
system that, at this point, must be written in C++ (using eVC4). The parent
app (written in VCS2003) contains a button ([File Transfer]) that packages
the data in an XML file and adds it to a "queue". Then, it starts the comm
process (child app) if it isn't already running. All of this takes place
when the device is docked in a special cradle.
I need to be able to:
1) Get the "application" handle of the child, if it exists; or create the
process and get the handle (starting a child app seems to work with no
problem). The message functions require an HWND, which I believe is the
same as an IntPtr, but I'm unable to properly convert/use it.
2) Send a message to the child app to tell it to minimize or maximize. In
other words, I want it to "sleep" in the background until it's needed, and
then become visible.
Caveats:
I am doing this with Windows CE Pocket PC version 4.20. I'm also using CF
1.0. I also have OpenNETCF 1.4 available. I can't seem to get CF 2.0 to
work on this hardware/OS.
Can someone...anyone...explain to me how this is done, or point me to a
resource?