Index SD Card?!

What board are you using this with? You need to bear in mind that storing an array of paths could take more memory than you have...

Are you sure that this is the way you really want to do it?