am start -D -a android.intent.action.SEND -t "image/jpeg" -e
"android.intent.extra.STREAM" "file://sdcard/download/
downloadfile-1.jpeg"
Starting: Intent { act=android.intent.action.SEND typ=image/jpeg (has
extras) }
After issuing the command, the chooser comes up and I select GMail.
When I select GMail, it gets a Force Close. Here's the relevant log
statements (AFAIK).
03-11 15:45:37.224 I/ActivityManager( 1014): Starting activity: Intent
{ act=android.intent.action.SEND typ=image/jpeg flg=0x10000000
cmp=android/com.android.internal.app.ResolverActivity (has extras) }
03-11 15:45:37.716 I/ActivityManager( 1014): Displayed activity
android/com.android.internal.app.ResolverActivity: 481 ms (total 481
ms)
03-11 15:45:43.709 I/ActivityManager( 1014): Starting activity: Intent
{ act=android.intent.action.SEND typ=image/jpeg flg=0x13800000
cmp=com.google.android.gm/.ComposeActivityGmail (has extras) }
03-11 15:45:43.732 I/ActivityManager( 1014): Starting activity: Intent
{ act=android.intent.action.SEND typ=image/jpeg flg=0x2800000
cmp=com.google.android.gm/.ComposeActivity (has extras) }
03-11 15:45:43.904 D/dalvikvm(21004): GC freed 1261 objects / 73576
bytes in 51ms
03-11 15:45:43.990 W/Bundle (21004): Key android.intent.extra.STREAM
expected Parcelable but value was a java.lang.String. The default
value <null> was returned.
03-11 15:45:43.998 W/Bundle (21004): Attempt to cast generated
internal exception:
03-11 15:45:43.998 W/Bundle (21004): java.lang.ClassCastException:
java.lang.String
03-11 15:45:43.998 W/Bundle (21004): at
android.os.Bundle.getParcelable(Bundle.java:1043)
03-11 15:45:43.998 W/Bundle (21004): at
com.google.android.gm.ComposeActivity.initFromExtras(ComposeActivity.java:
871)
03-11 15:45:43.998 W/Bundle (21004): at
com.google.android.gm.ComposeActivity.finishOnCreateAfterAccountSelected(ComposeActivity.java:
1154)
03-11 15:45:43.998 W/Bundle (21004): at
com.google.android.gm.ComposeActivity.onCreate(ComposeActivity.java:
332)
03-11 15:45:43.998 W/Bundle (21004): at
android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:
1047)
03-11 15:45:43.998 W/Bundle (21004): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2459)
03-11 15:45:43.998 W/Bundle (21004): at
android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:
2512)
03-11 15:45:43.998 W/Bundle (21004): at
android.app.ActivityThread.access$2200(ActivityThread.java:119)
03-11 15:45:43.998 W/Bundle (21004): at android.app.ActivityThread
$H.handleMessage(ActivityThread.java:1863)
03-11 15:45:43.998 W/Bundle (21004): at
android.os.Handler.dispatchMessage(Handler.java:99)
03-11 15:45:43.998 W/Bundle (21004): at
android.os.Looper.loop(Looper.java:123)
03-11 15:45:43.998 W/Bundle (21004): at
android.app.ActivityThread.main(ActivityThread.java:4363)
03-11 15:45:43.998 W/Bundle (21004): at
java.lang.reflect.Method.invokeNative(Native Method)
03-11 15:45:43.998 W/Bundle (21004): at
java.lang.reflect.Method.invoke(Method.java:521)
03-11 15:45:43.998 W/Bundle (21004): at
com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:860)
03-11 15:45:43.998 W/Bundle (21004): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
03-11 15:45:43.998 W/Bundle (21004): at
dalvik.system.NativeStart.main(Native Method)
03-11 15:45:43.998 D/AndroidRuntime(21004): Shutting down VM
03-11 15:45:43.998 W/dalvikvm(21004): threadid=3: thread exiting with
uncaught exception (group=0x4001b190)
03-11 15:45:43.998 E/AndroidRuntime(21004): Uncaught handler: thread
main exiting due to uncaught exception
03-11 15:45:44.005 E/AndroidRuntime(21004):
java.lang.RuntimeException: Unable to start activity
ComponentInfo{com.google.android.gm/
com.google.android.gm.ComposeActivity}: java.lang.NullPointerException
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2496)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:
2512)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.app.ActivityThread.access$2200(ActivityThread.java:119)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.app.ActivityThread$H.handleMessage(ActivityThread.java:1863)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.os.Handler.dispatchMessage(Handler.java:99)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.os.Looper.loop(Looper.java:123)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.app.ActivityThread.main(ActivityThread.java:4363)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
java.lang.reflect.Method.invokeNative(Native Method)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
java.lang.reflect.Method.invoke(Method.java:521)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
com.android.internal.os.ZygoteInit
$MethodAndArgsCaller.run(ZygoteInit.java:860)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
dalvik.system.NativeStart.main(Native Method)
03-11 15:45:44.005 E/AndroidRuntime(21004): Caused by:
java.lang.NullPointerException
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.provider.Gmail$AttachmentOrigin.localFileExtras(Gmail.java:
1710)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
com.google.android.gm.ComposeActivity.addAttachment(ComposeActivity.java:
521)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
com.google.android.gm.ComposeActivity.initFromExtras(ComposeActivity.java:
872)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
com.google.android.gm.ComposeActivity.finishOnCreateAfterAccountSelected(ComposeActivity.java:
1154)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
com.google.android.gm.ComposeActivity.onCreate(ComposeActivity.java:
332)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:
1047)
03-11 15:45:44.005 E/AndroidRuntime(21004): at
android.app.ActivityThread.performLaunchActivity(ActivityThread.java:
2459)
03-11 15:45:44.005 E/AndroidRuntime(21004): ... 11 more
03-11 15:45:44.013 I/Process ( 1014): Sending signal. PID: 21004 SIG:
3
03-11 15:45:44.013 I/dalvikvm(21004): threadid=7: reacting to signal 3
03-11 15:45:44.021 I/dalvikvm(21004): Wrote stack trace to '/data/anr/
traces.txt'
03-11 15:45:44.177 I/DumpStateReceiver( 1014): Added state dump to 1
crashes
--
You received this message because you are subscribed to the Google Groups "android-platform" group.
To post to this group, send email to android-...@googlegroups.com.
To unsubscribe from this group, send email to android-platfo...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/android-platform?hl=en.
Perhaps I could write a simple app that handles a custom intent and
essentially forwards it as the SEND intent with a proper URI based on
the string received?
> > android-platfo...@googlegroups.com<android-platform%2Bunsu...@googlegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/android-platform?hl=en.
>
> --
> Dianne Hackborn
> Android framework engineer
To unsubscribe from this group, send email to android-platfo...@googlegroups.com.