How to Send Data to Other App in Android Studio – Mobile App Development, Android App Development, iphone App Development class="post-template-default single single-post postid-4203 single-format-standard wp-custom-logo"

How to Send Data to Other App in Android Studio

Android defines several actions, including ACTION_SEND which, as you can probably guess, indicates that the intent is sending data from one activity to another, even across process boundaries. To send data to another activity, all you need to do is specify the data and its type, the system will identify compatible receiving activities and display them to the user.

Send Text Content

Android provides intent library to share data between activities an application in order to use it as share intent, we have to specify the type of the share intent to ACTION_SEND.
Intent shareIntent=new Intent();
Next thing you need to is to define the type of data to pass, and then pass the data.

shareIntent.PutExtra(Intent.EXTRA_TEXT, “Helloo from mobilemerit”);
startActivity(Intent.createChooser(shareIntent, “Share”));
if you call Intent.createChooser(), passing it your Intent object, it returns a version of your intent that will always display the chooser.

Send Binary Content

Binary data is shared using the ACTION_SEND action combined with setting the appropriate MIME type and placing the URI to the data in an extra named EXTRA_STREAM. This is commonly used to share an image but can be used to share any type of binary content:

[code lang=”js”]
Intent shareIntent = new Intent();
shareIntent.putExtra(Intent.EXTRA_STREAM, uriToImage);
startActivity(Intent.createChooser(shareIntent, getResources().getText(R.string.send_to)));

Create a new project in Android Studio

File – New Android Project

How to Send Data to Other App in Android Studio
How to Send Data to Other App in Android Studio

[code lang=”js”]
public class MainActivity extends ActionBarActivity {
Button button ;

protected void onCreate(Bundle savedInstanceState) {
button = (Button) findViewById(;
button.setOnClickListener(new View.OnClickListener() {
public void onClick(View v) {



private void shareIntent() {
Intent shareIntent = new Intent();
shareIntent.putExtra(Intent.EXTRA_TEXT, "Heloo from mobilemerit");
startActivity(Intent.createChooser(shareIntent, "Share"));
public boolean onCreateOptionsMenu(Menu menu) {
// Inflate the menu; this adds items to the action bar if it is present.
getMenuInflater().inflate(, menu);
return true;


[code lang=”js”]
<RelativeLayout xmlns:android=""

android:text="Button to share somthing"
android:layout_centerHorizontal="true" />



How to Send Data to Other App in Android Studio

Warning: _() expects exactly 1 parameter, 2 given in /home2/mobilemeri7/public_html/wp-content/themes/mobilemerit/comments.php on line 28

Write a Reply or Comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Crack Accounts admin panel bypass Tiktok hackleme sitesi Nulled Scripts Nulled Script ioncube decoder iphone sızma valorant hackleme Crack script Brute force programı Brute force yapma internetten para kazanma Evde para kazanmanın yolları Öğrenciler için internetten para kazanma yolları valorant combo Brute force programı Açıklı siteler SQL Açıklı siteler CMS Brute Force kaçağı bulmasu tesisatçısıjigolo siteleri arkadaş bulankara nakliyatankara nakliyatistanbul nakliyatgay sohbetbatak oynatavla oynagabile sohbetokey oynaoyunlar oyna #yaslikurt# sex geschichten sex geschichten brazzers rot media instagram banned service Hack haber Hacklink satışı Hacklink Çift faktör kıran telif scripti instagram hackleme sitesi instagram hackleme sitesi Bahis scripti Hack sitesi Crack forum Crack forum Crack Crack Forum instagram hackleme sitesi instagram hesap kapatma instagram hesap kapatma formları instagram hesap kapatma method instagram faktör geçme instagram faktör kırma instagram telif scripti Instagram Telif Scripti 2022 instagram hackleme sitesi apili telif scripti Facebook Temalı Telif Scripti