Android Question Compile error res\mipmap-anydpi-v26\ic_launcher.xml

RB Smissaert

Well-Known Member
Licensed User
Longtime User
Updated to the latest SDK and recources and also latest B4A version.
When compiling I get this error:

res\mipmap-anydpi-v26\ic_launcher.xml:7: error: not well-formed (invalid token).

Any suggestions how to fix this?

RBS
 

RB Smissaert

Well-Known Member
Licensed User
Longtime User
Updated to the latest SDK and recources and also latest B4A version.
When compiling I get this error:

res\mipmap-anydpi-v26\ic_launcher.xml:7: error: not well-formed (invalid token).

Any suggestions how to fix this?

RBS
Forgot to put the content of ic_launcher.xml:

<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@mipmap/background"/>
<foreground android:drawable="@mipmap/foreground"/>
</adaptive-icon>

#AdditionalJar: com.android.support:support-v4
#AdditionalJar: com.google.android.gms:play-services-location

RBS
 
Upvote 0

RB Smissaert

Well-Known Member
Licensed User
Longtime User
Forgot to put the content of ic_launcher.xml:

<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@mipmap/background"/>
<foreground android:drawable="@mipmap/foreground"/>
</adaptive-icon>

#AdditionalJar: com.android.support:support-v4
#AdditionalJar: com.google.android.gms:play-services-location

RBS
In case this is the problem, this is in the manifest file:

SetApplicationAttribute(android:icon, "@mipmap/ic_launcher")
CreateResource(mipmap-anydpi-v26, ic_launcher.xml,
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@mipmap/background"/>
<foreground android:drawable="@mipmap/foreground"/>
</adaptive-icon>

#AdditionalJar: com.android.support:support-v4
#AdditionalJar: com.google.android.gms:play-services-location
)

RBS
 
Upvote 0

RB Smissaert

Well-Known Member
Licensed User
Longtime User
In case this is the problem, this is in the manifest file:

SetApplicationAttribute(android:icon, "@mipmap/ic_launcher")
CreateResource(mipmap-anydpi-v26, ic_launcher.xml,
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@mipmap/background"/>
<foreground android:drawable="@mipmap/foreground"/>
</adaptive-icon>

#AdditionalJar: com.android.support:support-v4
#AdditionalJar: com.google.android.gms:play-services-location
)

RBS
No idea why:

gms:play

in my posted text is replaced with:

gms[smily icon]lay

RBS
 
Upvote 0

RB Smissaert

Well-Known Member
Licensed User
Longtime User
Do you want this gms:Play?
Indeed.
It wasn't relevant to the error, which was the misplaced closing bracket.
Manifest should have this instead:

'--------------------------------------------------------------------------------------
SetApplicationAttribute(android:icon, "@mipmap/ic_launcher")
CreateResource(mipmap-anydpi-v26, ic_launcher.xml,
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@mipmap/background"/>
<foreground android:drawable="@mipmap/foreground"/>
</adaptive-icon>)

#AdditionalJar: com.android.support:support-v4
#AdditionalJar: com.google.android.gms:play-services-location
'--------------------------------------------------------------------------------------

I think I have it all fixed now.

RBS
 
Upvote 0
Top