User Tools

Site Tools


intents:open_apps

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
intents:open_apps [2016/05/09 16:41]
mxgh2000 created
intents:open_apps [2021/10/29 14:59] (current)
al4he6 Added "Other Settings" section
Line 1: Line 1:
 **Open default browser app** **Open default browser app**
- +<code>app.SendIntent(null, null, 
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_BROWSER"); +"android.intent.action.MAIN", 
 +"android.intent.category.APP_BROWSER"); 
 +</code>
 **Open default music app** **Open default music app**
- +<code>app.SendIntent(null, null,  
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_MUSIC"); +"android.intent.action.MAIN",  
 +"android.intent.category.APP_MUSIC"); 
 +</code>
 **Open default calculator app** **Open default calculator app**
- +<code> 
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_CALCULATOR"); +app.SendIntent(null, null,  
 +"android.intent.action.MAIN",  
 +"android.intent.category.APP_CALCULATOR"); 
 +</code>
 **Open default contacts app** **Open default contacts app**
- +<code> 
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_CONTACTS"); +app.SendIntent(null, null,  
 +"android.intent.action.MAIN",  
 +"android.intent.category.APP_CONTACTS"); 
 +</code>
 **Open default email app** **Open default email app**
 +<code>
 +app.SendIntent(null, null,
 +"android.intent.action.MAIN", 
 +"android.intent.category.APP_EMAIL");
 +</code>
 +**Open default maps app**
 +<code>
 +app.SendIntent(null, null, 
 +“android.intent.action.MAIN”, 
 +“android.intent.category.APP_MAPS”);
 +</code>
 +As an alternative, you may wish to open Google Maps specifically - the code should really be on [[intents:google_maps|this separate page]]
  
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_EMAIL");+  app.SendIntent( 
 +    "com.google.android.apps.maps", 
 +    null, 
 +    "android.intent.action.VIEW", 
 +    "android.intent.category.DEFAULT", 
 +    "geo:0,0?q=34.5678,123.4567 (Placename)  // uri argument 
 +  );
  
-**Open default maps app** +Replace the coordinates and Placename in the uri argument with those for the desired location. (Optionallyyou can omit Placename along with the parentheses.) 
- +
-app.SendIntent(nullnull, "android.intent.action.MAIN", "android.intent.category.APP_MAPS");+
  
 **Open default gallery app** **Open default gallery app**
- +<code> 
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_GALLERY"); +app.SendIntent(null, null,  
 +"android.intent.action.MAIN",  
 +"android.intent.category.APP_GALLERY"); 
 +</code>
 **Open default calendar app** **Open default calendar app**
- +<code> 
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_CALENDAR"); +app.SendIntent(null, null,  
 +"android.intent.action.MAIN",  
 +"android.intent.category.APP_CALENDAR"); 
 +</code>
 **Open default market app** **Open default market app**
 +<code>
 +app.SendIntent(null, null, 
 +"android.intent.action.MAIN", 
 +"android.intent.category.APP_MARKET");
 +</code>
 +**Open default messaging app**
 +<code>
 +app.SendIntent(null, null, 
 +"android.intent.action.MAIN", 
 +"android.intent.category.APP_MESSAGING");
 +</code>
 +**Open bluetooth settings**
 +<code>
 +app.SendIntent(null,null,
 +"android.settings.BLUETOOTH_SETTINGS" )
 +</code>
 +**Open WiFi settings**
 +<code>
 +app.SendIntent(null,null,
 +"android.settings.WIFI_SETTINGS" )
 +</code>
  
-app.SendIntent(null, null, "android.intent.action.MAIN", "android.intent.category.APP_MARKET"); +**Other Settings**\\ 
- +\\ 
-**Open default calendar app** +See https://developer.android.com/reference/android/provider/Settings\\ 
- +The Constants section contains Actions (use as 3rd parameter on SendIntent,\\ 
-app.SendIntent(null, null, "android.intent.action.MAIN""android.intent.category.APP_MESSAGING");+replacing ACTION_ by android.settings.)\\
intents/open_apps.1462812116.txt.gz · Last modified: 2016/05/10 00:41 (external edit)