This sounds implausible to me, but I just thought I'd ask.
There exists a .NET application with a button in it. I cannot edit this application source, its a pre-existing application.
I wish to, from my application, programatically raise the click event for that button.
Is this possible?
The process would need to be running in order for it to perform an event, such as a button click. At that point, you have a few options for how to raise the button click event.
One way would be IPC (Inter-process Communication), using sockets or pipes between the two programs. You could also use shared memory if you prefer that option.
You would basically have to have the application with the button listening on a socket or pipe for a request to be sent. Once it is received, it can then call its own button click event from there.
The key is that both processes must be running and you must somehow send the other process a signal telling it to launch its button click event.