0
設備之間的藍牙共享文件,出現: - 無法打開共享文件。藍牙文件共享 - 無法打開共享文件
我想送存儲在圖片目錄下的圖像,以及我的照片的名字是:kitkat.jpg
我是給錯誤的道路?
Intent intent = new Intent();
intent.setAction(Intent.ACTION_SEND);
intent.setComponent(new ComponentName(
"com.android.bluetooth",
"com.android.bluetooth.opp.BluetoothOppLauncherActivity"));
intent.setType("image/jpeg");
File file = new File(Environment.getExternalStoragePublicDirectory
(Environment.DIRECTORY_PICTURES).toString() + "/kitkat.jpg");
intent.putExtra(Intent.EXTRA_STREAM, Uri.fromFile(file));
startActivity(intent);
我在圖片目錄中存儲圖片,即:kitkat.jpg ...告訴我提供的路徑是否有誤 – Sun
檢查更新的答案 –