I am running into an issue where I am creating a comma delimited file based on a query result. So I have a CFFile "Append" inside a Query Loop. I am trying to Lock the File Access so this is the hierarchy of my code in pseudo-code
cftry cflock name="myFileLock" loop query file Append /loop /cflock cfcatch <!-- if there was an error try and loop through query and append to file again --> cflock name="myFileLock" query loop file append /loop /cflock /cfcatch /cftry What I am getting is a sharing violation when I try appending to the file inside the cfcatch. Do I need to name the second lock differently? Is there a function in Coldfusion where I can test to see if there is a sharing violation before trying to append? Should I nest my code differently? Meaning should the try catch only be around the actual file append? Again all help is greatly appreciated. I look forward to hearing others' input and suggestions. Thanks, Ali ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Message: http://www.houseoffusion.com/lists.cfm/link=i:4:239198 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54