In given code lbl[0].getTextColor() is giving Error but i don\'t know how to get text color of textview in java file please help me.
public void angry(View v)
{
There is one important thing to remember: getCurrentTextColor() as well as similar methods like getCurrentHintTextColor() and getHighlightColor() return int value not hex mainly used to define colors. That could even be more confusing as this is negative number, for instance for red it is -65536, for green -16711936 and for white -1.
To make it simple this is because getCurrentTextColor() returns the difference between current color and white color value (both in decimal) minus 1. The expression is: CurrentColor-(WhiteColor+1), where white is 16777215. Of course for standard colors you could use predefined constants like Color.GREEN or Color.MAGENTA, but knowing that you could use effectively getCurrentTextColor() for any colors.
You could read even more about setting and getting colors in Android at http://android4beginners.com/2013/07/lesson-1-3-how-to-change-a-color-of-text-and-background-in-textview/