merge debug resources FAILED

4.2k views Asked by At

I'm using Android Studio and I have this error during the build of the project:

:app:mergeDebugResources FAILED Error:Execution failed for task ':app:mergeDebugResources'. Unsupported node 'item' in file C:\Users\Mh2\Desktop\IlMartino2doppiofinal\app\src\main\res\values\styles.xml

I tried to clean and rebuild the project but it seems not to be the solution. Here there is my styles.xml file:

<resources>

    <!-- Base application theme. -->
    <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"/>

        <!-- Customize your theme here. -->

        <item name="homeAsUpIndicator">@drawable/ic_drawer</item>
        <item name="android:homeAsUpIndicator">@drawable/ic_drawer</item>

        <!-- colorPrimary is used for the default action bar background -->
        <item name="colorPrimary">@color/black</item>

        <!-- colorPrimaryDark is used for the status bar
        <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
        -->

        <!-- colorAccent is used as the default value for colorControlActivated
             which is used to tint widgets -->


        <!-- You can also set colorControlNormal, colorControlActivated
             colorControlHighlight & colorSwitchThumbNormal. -->
        <item name="colorControlNormal">@color/purple</item>
        <item name="colorControlActivated">@color/red</item>
        <item name="colorControlHighlight">@color/darkred</item>
        <item name="colorSwitchThumbNormal">@color/darkorange</item>



</resources>

How can I find a solution?

1

There are 1 answers

0
Nicholas Ng On

here:

<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar"/>

you closed it with />

You should make it like

<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">

    <item........

</style>