Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

error: expected color but got (raw string) color/gray

I have switched to android studio 3. after many problem that I fixed, I got this error:

color/colorPrimary but i go this error:Error:(87, 5) error: expected color but got (raw string) color/gray

enter image description here

like image 297
Nawrez Avatar asked Nov 02 '17 10:11

Nawrez


1 Answers

You forgot to add @ before color/colorPrimary

change it like @color/colorPrimary

sample code

 <style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
        <!-- Customize your theme here. -->
        <item name="colorPrimary">@color/colorPrimary</item>
        <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
        <item name="colorAccent">@color/colorAccent</item>

    </style>
like image 151
AskNilesh Avatar answered Nov 17 '22 03:11

AskNilesh