Android Question Application icon on B4XMainPage

Sergey_New

Well-Known Member
Licensed User
Longtime User
How to install it like it was in B4A?
Only B4XMainPage needs this.
 

Sabotto

Active Member
Licensed User
In "Main" Module
B4X:
#Region Project Attributes
   
    #PackagerProperty: IconFile = ..\Files\icona200.ico
   
#End Region
 
Upvote 0

Sabotto

Active Member
Licensed User
The way I have indicated serves to set the icon you will have for the .exe file
You will indicate the path with a relative link t the folder.
Assuming you have the icon in your project's "MyFiles" folder, you'll write "..\MyFiles\icon_name.ico"
 
Upvote 0

klaus

Expert
Licensed User
Longtime User
#PackagerProperty: IconFile = ..\Files\icona200.ico

This is B4J not B4A.

In B4A and B4XPages nothing has changed.

1698917738270.png
 
Upvote 0

Sergey_New

Well-Known Member
Licensed User
Longtime User
In B4A and B4XPages nothing has changed.
I select the file:
1.png
An "Access Denied" message appears. The file at the selected address is deleted.
 
Upvote 0

Sabotto

Active Member
Licensed User
I tried with your path and the same icon and it gives problems. Choose another path and icon (use the Files folder)
 
Upvote 0

Sergey_New

Well-Known Member
Licensed User
Longtime User
It can be anywhere on your disk, and select it with the File Explorer.
No matter where I place the file,
icon.png
there is no result.
 

Attachments

  • ThreePagesExample.zip
    410.4 KB · Views: 49
Upvote 0

ilan

Expert
Licensed User
Longtime User
#PackagerProperty: IconFile = ..\Files\icona200.ico

This is B4J not B4A.

In B4A and B4XPages nothing has changed.

View attachment 147475
this will not always choose the icon file. if you will in the future update the app and compile you may end with the default b4a icon and not your choosen icon.

the right way to do it is like this:

 
Upvote 0

ilan

Expert
Licensed User
Longtime User
For me it still works, but i have no projects on PlayStore.
in the past i always used this method but in the last 1-2 years i noticed that when i compile old project the choosen icon is not the app icon. if you dont forget to choose the icon before you compile it to the store you will not have any issues but for me it was not the case. using adaptive icons works for me.
 
Upvote 0

Sergey_New

Well-Known Member
Licensed User
Longtime User
the right way to do it is like this:
I did as indicated in the link. There is no result. I am attaching the project, please look at what is wrong in it.
 

Attachments

  • ThreePagesExample.zip
    16.7 KB · Views: 45
Upvote 0

klaus

Expert
Licensed User
Longtime User
I have no result either.
I have never used adaptive icons.
I do not know what happens.

Then I opened the ManifestEditor and erased everything in it and closed and saved it.
When launching the program the next time a new default Manifest file is created.
Then i added a new icon in the IDE, compiled, and it works as expected.

Maybe ilan knows what happens.
 
Upvote 0

ilan

Expert
Licensed User
Longtime User
everything works as expected.
the problem is that your forground image in mipmap-xxxhdpi is blank and that is what you see in the phone
change it and you will see that it works fine

(updated project included)
 

Attachments

  • ThreePagesExample v2.zip
    143.5 KB · Views: 48
Upvote 0

Sergey_New

Well-Known Member
Licensed User
Longtime User
everything works as expected.
Looked at the attached example. You probably didn’t understand me, it created an adaptive application icon, and I need the icon to be displayed on the B4XMainPage page:

3.png
 
Upvote 0

aeric

Expert
Licensed User
Longtime User
Go to Manifest Editor and edit as following:

B4X:
'CreateResourceFromFile(Macro, Themes.LightTheme)
SetApplicationAttribute(android:theme, "@android:style/Theme.Holo.Light")
 

Attachments

  • BackToHolo.zip
    13.8 KB · Views: 47
Upvote 0
Top