Andrea,

  Lucky you!  It is already a list, only it is delimited by carriage returns
rather than commas.  You can loop over it just like any other list, you'll
just need to specify the delimiter to be a carriage return (#chr(10)#)
rather than a comma.  OR, if you want to change it to be a standard comma
separated list, you can use the ListChangeDelims(list, new_delimiter [,
delimiters ]) function.

<CFFILE ACTION="Read"
         FILE="full_path_name"
         VARIABLE="email_list">
<CFSET lEmailList = ListChangeDelims(email_list,",",CHR(10))>


Chris Evans
[EMAIL PROTECTED]
http://www.fuseware.com



-----Original Message-----
From: Andrea Wasik [mailto:[EMAIL PROTECTED]]
Sent: Tuesday, March 28, 2000 10:50 AM
To: [EMAIL PROTECTED]
Subject: Easiest way to get a text file into a List?


I have a text file that I need to get into a list or an array so I can
compare it to the results of a query. Anyhow how can I read in that file and
turn it into a list? The file is made up of email addresses, one per line,
no comma delimiters, just carriage returns.

Thanks

Andrea

............................................................................
.....
iWon.com     http://www.iwon.com     why wouldn't you?
............................................................................
.....

----------------------------------------------------------------------------
--
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or
send a message to [EMAIL PROTECTED] with 'unsubscribe' in
the body.


------------------------------------------------------------------------------
Archives: http://www.eGroups.com/list/cf-talk
To Unsubscribe visit 
http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk or send a 
message to [EMAIL PROTECTED] with 'unsubscribe' in the body.

Reply via email to