简体   繁体   中英

Is there a decent way to send “Windows messages” between Adobe AIR and .NET, or do you need to use sockets?

We have an Adobe AIR app and a VB.NET app running on the same machine, and we want these to establish point-to-point communication. One option that immediately comes to mind is sockets. However Windows messages have also been brought up. Flash seems to have several tutorials and such for using sockets, but not so much is coming up on Google for some sort of native "Windows message" communication.

I haven't worked with a lot of the Windows API before, aside from just using .NET in general, so I'm not quite sure what Windows messages look like or how they work. I'm not sure, for instance, whether they're a specifically .NET construct.

Either way, if Adobe AIR easily supports passing Windows messages back and forth with a .NET app, how is this done? (Just one basic example or other resource would get me started.) Or can you only do this through native extensions to AIR? (That would be out of the question, in this case.) Thanks.

AIR can run external .exe file with so called NativeProcess .

So you can write some external bat or simple exe that does your job (sends specific messages) and call it through AIR. I haven't heard/seen any "Windows message" being available for AIR.

I haven used it approach only for similar exe tasks, but you should also check the manual I've provided to see what else you can do. There might be even more options that this. It's stated that The NativeProcess class lets an AIR application execute native processes on the host operating system as well as The AIR applcation can monitor the standard input (stdin) and standard output (stdout) stream of the process as well as the process's standard error (stderr) stream .

I'm not very into that, but I hope there's some point you should understand and might help you more than executing external .exe :)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM