Assign picture to number, Table of all pictures in folder

Hello.

Im developing app and i need some help.

I have a folder with X pictures.

How can I assign each picture to a number, that i will be able to display one picture on screen and when I slide to left number will change and another picture in numerical order will display?

I want that my app save picture to a folder and then display it in another screen.

I dont want to be limited with the number of photos I take and save to this folder.

Any help is appreciated.

Tnx,

Rok

Have you tried naming the pictures 1.png/2.png/3.png/etc and in the code doing:

1
2
local var = 1
local img = display.newImage(var..".png", 0, 0)

One way is that you number than instead of having a filename

The other way is that you create and manage an index just like the FAT Table.

cheers,

?:)

views:1262 update:2011/11/10 9:30:09
corona forums © 2003-2011