Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save trycf/346a005cdb72b844a83ca21eacb85035 to your computer and use it in GitHub Desktop.
Save trycf/346a005cdb72b844a83ca21eacb85035 to your computer and use it in GitHub Desktop.
TryCF Gist
<cfscript>
excelColumnList = 'YR,MNTH,ANNIV,FIRST NAME,LAST NAME,EMAIL,NOTES';
mappedColumnList= ',YEAR,MONTH,,First Name,Last Name,Email,COMMENTS';
mappedColumn= 'Last Name';
mappedColumnList = mappedColumnList.replaceall("^(,*)","") ;
local.index = ListFindNoCase(mappedColumnList, mappedColumn,',', true);
local.returnValue = ListGetAt(excelColumnList,local.index,",",true) ;
writeDump(local.returnValue);
</cfscript>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment