Single file upload

I would like to allow user to only upload one file at a time using the flash uploader interface.
I found around here a link to a hack allowing to create an error message when more than one file is selected but that’s not what I want.
I would like to only take the first file into consideration and just ignore the other files.