Damo, Did you try the attempt I outlined above (reproduced here)? You've got to get the lines into an array first, then you should be able to refer to them by [26] or [27], as Peter and I pointed out.
>How about something like this (untested): > ><cfset crlf = chr(13) & chr(10) /> ><cfset lineArray = reMatch(crlf, myFile) /> > ><cfif len(trim(lineArray[26]))> ><cfset invoiceNumber = trim(lineArray[26]) /> ><cfelse> ><cfset invoiceNumber = trim(lineArray[27]) /> ></cfif> > >The variable 'invoiceNumber' should now hold whichever line has content ... ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Want to reach the ColdFusion community with something they want? Let them know on the House of Fusion mailing lists Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:327391 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4