Show Web page:
Uri uri = uri.parse ("http://www.google.com");
Intent it = new Intent (Intent.action_view,uri);
StartActivity (IT);
Show Map:
Uri uri = uri.parse ("geo:38.899533,-77.036476");
Intent it = new Intent (Intent.action_view,uri);
StartActivity (IT);
Path planning:
Uri uri = Uri.parse ("http://maps.google.com/maps?f=d&saddr=startlat%20startlng&daddr=endlat%20endlng& Hl=en ");
Intent it = new Intent (Intent.action_view,uri);
StartActivity (IT);
Dial number:
Call the dialer URI uri = uri.parse ("tel:xxxxxx");
Intent it = new Intent (intent.action_dial, URI);
StartActivity (IT);
Uri uri = uri.parse ("tel.xxxxxx");
Intent it =new Intent (Intent.action_call,uri);
To use this, you must include it in the configuration file
Send Sms/mms:
Call the program that sends the SMS Intent it = new Intent (Intent.action_view);
It.putextra ("Sms_body", "The SMS Text");
It.settype ("vnd.android-dir/mms-sms");
StartActivity (IT);
Send sms URI uri = uri.parse ("smsto:0800000123");
Intent it = new Intent (intent.action_sendto, URI);
It.putextra ("Sms_body", "The SMS Text");
StartActivity (IT);
Send mms uri uri = uri.parse ("Content://media/external/images/media/23");
Intent it = new Intent (intent.action_send);
It.putextra ("Sms_body", "some text");
It.putextra (Intent.extra_stream, URI);
It.settype ("Image/png");
StartActivity (IT);
Send email
Uri uri = Uri.parse ("mailto:[email protected]");
Intent it = new Intent (intent.action_sendto, URI);
StartActivity (IT);
Intent it = new Intent (intent.action_send);
It.putextra (Intent.extra_email, "[EMAIL protected]");
It.putextra (Intent.extra_text, "The email body TEXT");
It.settype ("Text/plain");
StartActivity (Intent.createchooser (it, "Choose Email Client"));
Intent it=new Intent (intent.action_send);
String[] tos={"[email protected]"};
String[] ccs={"[email protected]"};
It.putextra (Intent.extra_email, TOS);
It.putextra (INTENT.EXTRA_CC, CCS);
It.putextra (Intent.extra_text, "The email body TEXT");
It.putextra (Intent.extra_subject, "The email SUBJECT text");
It.settype ("message/rfc822");
StartActivity (Intent.createchooser (it, "Choose Email Client"));
Add an attachment
Intent it= New Intent (intent.action_send);
It.putextra (Intent.extra_subject, "The email SUBJECT text");
It.putextra (Intent.extra_stream, "File:///sdcard/mysong.mp3");
Sendintent.settype ("Audio/mp3");
StartActivity (Intent.createchooser (it, "Choose Email Client"));
Play Multimedia
Intent it = new Intent (Intent.action_view);
Uri uri = uri.parse ("File:///sdcard/song.mp3");
It.setdataandtype (URI, "Audio/mp3");
StartActivity (IT);
Uri uri = Uri.withappendedpath (MediaStore.Audio.Media.INTERNAL_CONTENT_URI, "1");
Intent it = new Intent (Intent.action_view, URI);
StartActivity (IT);
Uninstall uri uri = uri.fromparts ("package", strpackagename, NULL);
Intent it = new Intent (Intent.action_delete, URI);
StartActivity (IT);
SDK Documentation android_sdk/docs/guide/appendix/g-app-intents.html
Android (call the system comes with some features)