I have 35 images named from pic1.png
to pic35.png
in my res\drawable
folder. I need to create array of this pics to fill my ListView. I know I need some loop.
int[] img;
for (int i = 1; i <= 35; i++) {
//here should be my loop body, but i dunno :( i tried this, but ofc this is wrong.
img = R.drawable.pic[i];
}
One more question:
is there any chance to manage my images in drawable
folder? I mean, if I have two packs of images, I can't do res\drawable\pack1
and res\drawable\pack2
folders, is the only way to manage images to give em names like pack1_pic1
etc?