513
Views
16
Comments
Solved
Modify mobile app icon

Hi,


i am trying to change the icon on my mobile application, but I got this error : 

I tried to follow this guide : 

https://success.outsystems.com/Documentation/10/Delivering_Mobile_Apps/Customize_Your_Mobile_App/Modify_the_App_Icon#Icons_JSON_Template


Here is the extensibility config I set :

{
    "resources" : "MyResources.zip",
    "icons" :
    {
        "android": [{

            "resource": "/path/to/android/icon.png",

            "density": "ldpi"

        },

        {

            "resource": "/path/to/android/icon.png",

            "density": "mdpi"

        },

        {

            "resource": "/path/to/android/icon.png",

            "density": "hdpi"

        },

        {

            "resource": "/path/to/android/icon.png",

            "density": "xhdpi"

        },

        {

            "resource": "/path/to/android/icon.png",

            "density": "xxhdpi"

        },

        {

            "resource": "/path/to/android/icon.png",

            "density": "xxxhdpi"

        }]
    }
}



Thanks in advance.

2020-12-15 11-23-41
César Afonso
Staff
Solution

Hello Tobit.

The problem is that you're pointing to the head of the the master and, a couple of days ago, they commited a new version of the plugin that doesn't seem to work..

You should use a tag. In this case, change the url of the plugin in your extensibility configuration to:

https://github.com/dpa99c/cordova-diagnostic-plugin.git#3.6.4 (previous version)


Here's more info: Section Guidelines to create a plugin, from the KB article Create a plugin

Let me know if it works

Thanks

2016-11-20 11-27-52
João Neves

Hi Tobit,

Did you set the path correctly? Is this path "/path/to/android/" correct?

2017-06-27 15-30-33
tBt

Hi Joao,

Actually I also a bit confused about the path, on what basis should I put the path.

I've tried  setting 3 path, and all failed with same error message :

1.  /path/to/android/icon.png

2. /MyResources.zip/icon.png

3. /DnmMAppraisal_Mobile/MyResources.zip/icon.png


here is what in resources.zip file


2016-11-20 11-27-52
João Neves

You should specify the path inside the zip file. In your case is just "/icon.png".

2017-06-27 15-30-33
tBt

I've changed it and now getting this error.


2020-12-15 11-23-41
César Afonso
Staff

Hello Tobit.

Does your app build without configuring the icon through extensibility (just to make sure the issue is with the icon)?

Also, why are you using extensibility to set the application icon? If you don't do anything, the application icon will be the icon you chose for your OutSystems application



Thanks

2017-06-27 15-30-33
tBt

César Afonso wrote:

Hello Tobit.

Does your app build without configuring the icon through extensibility (just to make sure the issue is with the icon)?

Also, why are you using extensibility to set the application icon? If you don't do anything, the application icon will be the icon you chose for your OutSystems application



Thanks


Hi Cesar,

the case is at first I dont set any icon for my app. 

Then in the middle of my dev, i want to change the apk icon to a picture, but after I upload an icon, I noticed that it also makes an error when generating apk.

2017-06-27 15-30-33
tBt

do I need to provide all icon formats ?

means there will be 6 types of icon png files on that zip files.

2020-12-15 11-23-41
César Afonso
Staff

Hello Tobit.

My suspicion is that the error is not related with the icon but probably some plugin you're using.

Can you try creating a clean app, use the icon and build (without plugins)? This way you can check if it's the icon or not.

Thanks

2017-06-27 15-30-33
tBt

Hi Cesar,

I've tried what you suggest. The result is ok.

Now, how can I identify the real culprit?


Thanks in advance.

2020-12-15 11-23-41
César Afonso
Staff

Hello Tobit.

The next step would be for you to remove the plugins one by one (or add them one by one in your clean app if it's easier) and see the culprit. The most common cause for an error when building an app is a plugin.

If you're using plugins that are not in the OutSystems supported plugins list, it's a good bet to start with those.

Thanks

2017-06-27 15-30-33
tBt

César Afonso wrote:

Hello Tobit.

The next step would be for you to remove the plugins one by one (or add them one by one in your clean app if it's easier) and see the culprit. The most common cause for an error when building an app is a plugin.

If you're using plugins that are not in the OutSystems supported plugins list, it's a good bet to start with those.

Thanks

Hi Cesar,

Now I've found the culprit. 

But what make me confused is the plugin function is working well. I've tried to re-publish the plugin, then publish it again, but still error when generating APK.


UserImage.jpg
Carrie Palmer

I found a detailed article which might come in handy https://www.androidcentral.com/hate-app-icon-heres-how-change-it . It mentions how to use Awesome Icons. I guess everybody knows about it. 

Similarly, outsystems has a detailed and very useful doc https://success.outsystems.com/Documentation/10/Delivering_Mobile_Apps/Customize_Your_Mobile_App/Modify_the_App_Icon

Do check for this article on mastering few important skills in mobile app development https://www.cestarcollege.com/blog/mobile-app/skillsets-a-professional-ios-developer-must-master/

2020-12-15 11-23-41
César Afonso
Staff

Hello Tobit.

If you're unable to generate the apk, how do you know the plugin functionality is working? What's the plugin that's causing the error?

Thanks

2017-06-27 15-30-33
tBt

Hi Cesar,

So here is what happen :

1. I make an app. While I'm developing, I need some plugin that can check if the location setting on hp is on / off.

2. So I add this plugin (attached) to my app. After that I generate APK. After installing new APK and test it, everything seems fine, and the function worked.

3. After a while, I decide I want to change the icon of my APK. After I change it, I tried to build the new APK. Now it returns an error like what I describe above.

CheckGPSLocation.oml
2020-12-15 11-23-41
César Afonso
Staff
Solution

Hello Tobit.

The problem is that you're pointing to the head of the the master and, a couple of days ago, they commited a new version of the plugin that doesn't seem to work..

You should use a tag. In this case, change the url of the plugin in your extensibility configuration to:

https://github.com/dpa99c/cordova-diagnostic-plugin.git#3.6.4 (previous version)


Here's more info: Section Guidelines to create a plugin, from the KB article Create a plugin

Let me know if it works

Thanks

2017-06-27 15-30-33
tBt

Hi Cesar,

tq very much, it works now.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.