Closed chiragbhatt3 closed 3 years ago
You can use the below snippet to launch the app gallery, packagename refers to the name of the package in appgallery
Intent.OperationBuilder operationBuilder = new Intent.OperationBuilder(); operationBuilder.withBundleName(HUAWEI_APP_GALLERY_URI_PREFIX); operationBuilder.withFlags(Intent.FLAG_ABILITY_NEW_MISSION); operationBuilder.withAction(HUAWEI_APP_GALLERY_ACTION); Operation operation = operationBuilder.build(); Intent intent = new Intent(); intent.setParam("APP_PACKAGENAME", packageName); intent.setOperation(operation); ability.startAbility(intent);
Query description
I am working on an open-source library for HarmonyOS app development which is used to prompt app users for rating the app on App Gallery. For that, I need to implement a method to launch the app gallery whenever the user agrees to give feedback. For Android, the same functionality is achieved through the following code
What is the alternative for this in HarmonyOS ?
Stackoverflow link:
https://stackoverflow.com/questions/68590480/how-to-implement-method-to-launch-app-gallery-in-hamonyos-application
Additional information
Developer Platform: Windows DevEco Studio version: 2.1.0.303 SDK API version: 5 SDK version: 2.1.1.21 Device: Not required Device OS version: Not required
Regards, Chirag