简体   繁体   中英

How Can I Communicate with another application?

I'd like ask you if there's a way to send information or commands to other applications. For example: a person is typing a message to one, and after ten seconds my program adds (by using the command append("text").to(EditText); ) a string like "hello" in the EditText of the message.

I discovered that information can be shared between different apps through ContentProviders

Is there a way to accomplish this?

This is only possible when the developer of this particular app predicted such behavior. It could be done simply by broadcasting intents between apps, but this "another" app must have a suitable Broadcast Receiver to make a use of this intents. http://developer.android.com/guide/components/intents-filters.html

Or, you can fire up an intent on another app and bundle your Data into it and pass it through Intent object. Check out this link. I purposely haven't written a code. I think everyone should learn on their own. Remember,The developer site is the Bible for Android.

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