0

I am in the process of using colorPrimary in my styles.xml file with Theme.AppCompat.Light as my theme. I encountered an No resource found that matches the given name: attr 'colorPrimary'. I used this question as a reference but it did not match what I was looking for. Here is my source code:

<resources xmlns:android="http://schemas.android.com/apk/res/android">

    <!--
        Base application theme, dependent on API level. This theme is replaced
        by AppBaseTheme from res/values-vXX/styles.xml on newer devices.
    -->
    <style name="AppBaseTheme" parent="Theme.AppCompat.Light">
        <!--
            Theme customizations available in newer API levels can go in
            res/values-vXX/styles.xml, while customizations related to
            backward-compatibility can go here.
        -->
        <item name="colorPrimary">#690</item>
    </style>

    <style name="FlipPremiumOpenScreenTheme" parent="Theme.AppCompat.Light">
        <!--
            Theme customizations available in newer API levels can go in
            res/values-vXX/styles.xml, while customizations related to
            backward-compatibility can go here.
        -->
        <item name="android:windowNoTitle">true</item>
    </style>

    <!-- Application theme. -->
    <style name="AppTheme" parent="AppBaseTheme">
        <!-- All customizations that are NOT specific to a particular API-level can go here. -->
    </style>

    <!-- Application theme. -->

</resources>

Is there anything I have overlooked?

Community
  • 1
  • 1
Daniel Burgner
  • 224
  • 2
  • 6
  • 16

1 Answers1

0

Change your code to:

<item name="android:colorPrimary">#690</item>
Avijit Karmakar
  • 8,890
  • 6
  • 44
  • 59