Nikhil Agrawal
Nikhil Agrawal

Reputation: 26558

Image in android not getting added to @drawable/

Hello I am developing an android application in which for a ListView I have to added an image to drawable folder but when I am adding it is giving the error.

This is the folders hierarchy of my project

enter image description here

This is the image I wanna add arrow.png

enter image description here

This is the error

[2013-04-03 20:57:37 - FileSharing] res/drawable/arrow.png: Invalid file name: must contain only [a-z0-9_.]

I have changes the file name 10 times according to the conventions but still the error is not going

Upvotes: 0

Views: 261

Answers (2)

edwin
edwin

Reputation: 8091

Well i think you must not put the image file in drawable folder.

you must chose these folder for putting images for your application

enter image description here

If you didn't see these folder create these folder inside res . Then clean and rebuild your project .Hope this would help you

Also Keep an eye one the name of images must contain only [a-z0-9_.]

I think the default choice is drawable-mdpi folder

Refer this

Upvotes: 1

AndroDev
AndroDev

Reputation: 3304

Clean your project and build again.

Sometimes eclipse behaves wierd.

Upvotes: 0

Related Questions