简体   繁体   中英

Not listing connected WiFi printer in android print panel

I'm using following code to print web-view from android app.

    private void createWebPrintJob(WebView webView) {

    PrintManager printManager = (PrintManager) this
          .getSystemService(Context.PRINT_SERVICE);

    PrintDocumentAdapter printAdapter = 
             webView.createPrintDocumentAdapter();

    String jobName = getString(R.string.app_name) + 
                        " Print Test";

    printManager.print(jobName, printAdapter,
           new PrintAttributes.Builder().build());
}

But android print panel not showing the available WiFi printer in print panel.

Note:

  • It shows "Google cloud print" and "save as PDF" option in android print panel.(API LEVEL 19)
  • I am using the Epson printer and I have installed Epson Printer Enabler on my android device.

I encountered the same issue. It appears that some devices lack cloud printing and therefore will need to install the official Google Cloud Print plugin/app.

You could suggest users to download the app if there are no printers being displayed.

https://play.google.com/store/apps/details?id=com.google.android.apps.cloudprint

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM