format string color to type iny code example Example: convert int color to hex android String hexColor = String.format("#%06X", (0xFFFFFF & intColor));