PrintConnect on Android Target API level 30


Audience

We are encountering 2 problems related to Android Target API level 30, when using PrintConnect to print labels:

1. Communication via Intent from our app to PrintConnect doesn't work on devices with Android 11 (API level 30), when compiling with Target API level 30. The print doesn't start and we're not receiving a response in out ResultReceiver. Logcat reports this line "ActivityManager: Unable to start service Intent { cmp=com.zebra.printconnect/.print.TemplatePrintService (has extras) } U=0: not found". This is a high priority problem, because it stops printing all together.

2. On Android API level 30, Storage Access Framework (SAF) is mandatory. Due to this, using PrintConnect with "local storage" selected as file storage is now almost impossible. We have to ask the user to choose the folder in which he wants to save the template (generated by the app), but once he chooses one, he's not bound to choose that again the next time we need to update the template or create a new one. A solution to this problem could be that PrintConnect exposes an API that accept a file/string and PrintConnect itself saves it in its private folder.

Target API level 30 is mandatory on the Play Store for new applications starting from august 2021 and for updates to existing applications starting november 2021, so this is a pressing issue.