How can I track down the cause of Android "found an invalid color" error

For future reference - this error is what you get if you have added an image as a 9-pack and it isn't yet properly formatted with the black pixel borders. The error message could be far more helpful, i.e. actually saying which file the error occurs with would be nice, but the solution is just to go through all your 9 pack files in Android Studio and open then save each of them.


First of all, check your layout directory in file explorer bcoz when you have made changes in the main layout file then you could have changed respective example: v-21 or v-13 layout file too. This error occurs when you apply some element property which is not supported by previous versions like v-21.

I hope I have given detail about this, if any explanations are needed plz let me know.

Tags:

Android