finding part of fole path

S

sheila

OK, here is what i have. I have a muisc list that I get from file
names from a playlist. i get the artist name and the song name from
the path of the file using playlist files (txt format), Now i want
the album name too. File name goes something like this:

d:\Music\Beatles\Rubber Soul\Beatles - Drive My Car.mp3

Album name is Rubber Soul and is always the last "path" entry before
the file name. Is there a formula that I can use to get "Rubber
Soul"??

TIA

Sheila
 
B

Biff

Hi!

Kind of ugly:

=MID(A1,FIND("~",SUBSTITUTE(A1,"\","~",LEN(A1)-LEN(SUBSTITUTE(A1,"\",""))-1))+1,FIND("~",SUBSTITUTE(A1,"\","~",LEN(A1)-LEN(SUBSTITUTE(A1,"\",""))))-1-FIND("~",SUBSTITUTE(A1,"\","~",LEN(A1)-LEN(SUBSTITUTE(A1,"\",""))-1)))

Biff
 
Top