【发布时间】:2015-09-28 22:41:40
【问题描述】:
我正在尝试通过 Intent 选择文件。 我到现在尝试的是这样的:
Intent intent = new Intent(Intent.ACTION_GET_CONTENT);
intent.setType("*/*");
startActivityForResult(intent, FILE_SELECT_CODE);
但是有了这个,我只能用图库应用拍照。
我的目标是通过 Android/Samsung 的标准文件管理器拍摄任何文件。
这也不起作用:
String manufactures = android.os.Build.MANUFACTURER;
if(manufactures.equalsIgnoreCase("samsung"))
{
Intent intent = new Intent("com.sec.android.app.myfiles.PICK_DATA");
intent.putExtra("CONTENT_TYPE", "*/*");
startActivityForResult(intent, FILE_SELECT_CODE);
}
感谢您的帮助!
【问题讨论】:
标签: java android file android-intent