Hi,
You don't even need a loop, you can use listfind().
Here's an example for what I usually use.
cheers,
fober
<cfset application.upload_allow=
"txt,doc,xls,ppt,mdb,htm,html,gif,tif,jpg,jpeg,png,zip,pdf,rtf">
<cfif isdefined("file_upload") IS TRUE>
<cfif evaluate("len(file_upload)")>
<cffile action="UPLOAD"
filefield="file_upload"
destination="#application.app_content_folder#"
nameconflict="MAKEUNIQUE">
<cfif listfind(application.upload_allow,
cffile.clientFileExt) Is 0>
...delete the file and error message
</cfif>
</cfif>
</cfif>