Arduino Forum

Using Arduino => Storage => Topic started by: novolo on Jun 07, 2013, 03:55 am

Title: How to get filename or file type with official SD.h ?
Post by: novolo on Jun 07, 2013, 03:55 am
Hello everyone.

I've seen examples with the SDfat in  the loop section.

But I'm using webduino and would like to know if there is a simple way to get the file name or file type of a file in the SD card using just the SD.h library?

Could no find an example out there.

Thank You,
Title: Re: How to get filename or file type with official SD.h ?
Post by: PaulS on Jun 10, 2013, 12:20 pm
Quote
But I'm using webduino and would like to know if there is a simple way to get the file name or file type of a file in the SD card using just the SD.h library?

Webduino doesn't give you a file handle. The only way to get a file handle is to open a file on the SD card. It seems to me that you could remember the name of the last file opened. Or, the name associated with a given handle, if you have more than one file open at a time.

Perhaps you need to explain your question differently.