我正在使用手机存储中的 Google 云打印打印 Pdf。我想通过替换它来使用 pdf URL。如何使用网址?例如:我想将 /print/test.pdf" 替换为 "www.example.com/print/test.pdf"
File file = new File(Environment.getExternalStorageDirectory().getAbsolutePath()+"/print/test.pdf");
Intent printIntent = new Intent(MainActivity.this,PrintDialogActivity.class);
printIntent.setDataAndType(Uri.fromFile(file),"application/pdf");
printIntent.putExtra("title", "Android print demo");
startActivity(printIntent);