• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps Problems with colors.xml

aleckan

Lurker
I have a colors.xml file located in the res/values fodler.

Code:
<?xml version="1.0" encoding="utf-8"?>
<resources>
	<color name="transparent">#00000000</color>
	<color name="menu_selected">#00feff9c</color>
	<color name="menu_unselected">#00cccccc</color>
</resources>

When I try to use this colors they can't be found. This is the code I use to get the colors (Android 2.0 if that matters).

Code:
android:textColor="@color/menu_selected"

and in I've tryed through the code...

Code:
text_1.setTextColor(getResources().getColor(R.color.menu_selected));

But this is what I get in the debug logcat inside eclipse.

11-06 02:34:15.916: WARN/ResourceType(63): Resources don't contain package for resource number 0x7f060000

What am I doing wrong?

Please help =)

best regards
Alexander
 
Back
Top Bottom