Getting path of a file (Not Dropfile)

Marcos's icon

In a umenu I have a bunch of mp3's listed (along with their file path) so that when I select them they play. For every mp3 selected/played I want the filepath of that .mp3. The only maxobject I have seen that can determine the filepath of a file is dropfile, but I am not dropping files, and dropfile does not accept any input. Any ideas?

Peter Nyboer's icon
Max Patch
Copy patch and select New From Clipboard in Max.

I think a simple example of what you are doing would help, as there's a million ways of doing this.
However, off the top of my head, you may want to look at "regexp"

Marcos's icon

That works nicely, thanks! I have never understood regexp and I hate it with a passion

Peter Nyboer's icon

There's a running regexp tutorial on this list. Also, the MMJ depot at cnmat has a regexp tutorial/example patch.
Download:http://cnmat.berkeley.edu/files/maxdl/ALL/CNMAT-Everything-OSX-MachO.tar.gz
unzip and go to:
/CNMAT-Everything-OSX-MachO/CNMAT_MMJ-Depot/tutors/object-tutors/about_regexp.maxpat

Regexp may be confusing, but it is your friend.