How to display a local image via adb shell

2019-01-25 22:25发布

I am trying to display a local image on my Samsung Note 3 via adb shell.
$adb shell am start -a android.intent.action.VIEW -n com.android.browser/.BrowserActivity -d file:///storage/emulated/legacy/Pictures/red.png $
this code works for my another display device, but not works for my Note 3, i get this error
Starting: Intent { act=android.intent.action.MAIN cmp=com.android.browser/.BrowserActivity } Error type 3 Error: Activity class {com.android.browser/com.android.browser.BrowserActivity} does not exist. i tried also this code
$adb shell am start -t image/* -d file:///storage/emulated/legacy/Pictures/red.png $

but still doesnt work. Can anybody help me, really appreciate for that!

标签: java android adb
1条回答
老娘就宠你
2楼-- · 2019-01-25 23:11

Solved myself:

adb shell am start -d file:///storage/emulated/legacy/Pictures/tiger.jpg -t image/jpg -a android.intent.action.VIEW

查看更多
登录 后发表回答