1. Start the shell.
2. Start the ActivityManager(am) command-line tool with appropriate parameters.
The syntax for the am command-line tool is the following.
ssue am command. am command syntax is as follow :
am [start|instrument]
am start [-a <action>] [-d ] [-t <mime_type>]
[-c <category> [-c <category>] ...]
[-e <extra_key> <extra_value> [-e <extra_key> <extra_value> ...]
[-n <component>] [-D] [<uri>]
am instrument [-e <arg_name> <arg_value>] [-p <prof_file>]
[-w] <component>
3. Start the web browser with the following command.
am start -a android.intent.action.MAIN -n com.android.browser/.BrowserActivity
to start your own application just type:
am start -a android.intent.action.MAIN -n "Your Package"/."Your Activity"
If you hare unsure of what your package and main activity are look in your manifest file:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.TordSoft.HelloWorld">
<application android:icon="@drawable/icon">
<android:name=".HelloWorld" android:label="@string/app_name">
<intent-filter>
<action android:value="android.intent.action.MAIN" />
<category android:value="android.intent.category.LAUNCHER" /> </intent-filter>
</activity></application>..</manifest>
Hi Friend I follow this blog..
ReplyDeleteWhen you run am (even without any argument, so it displays usage) and USB debugging is disabled the usage is displayed but the command never returns, it hangs.
ReplyDeleteAny comment?
such a wonderful post.I like your blog ambition.I came to know some useful application about smart phone platform.
ReplyDeleteInteresting post. I learn something more challenging on different blogs everyday. It will always be stimulating to read content from other writers and practice a little something from their store.
ReplyDeleteGreat informative post . You have included a lot of information that i was needed. now i can optimize my tablet myself . Thanks to sharing this post.
ReplyDeleteApplication Release Management
secret android commands : http://www.app-mug.com/2017/01/important-android-commands.html
ReplyDelete