• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

Lists

ColdFusion lists give us the capability to store several values as a single variable. For example, the following code shows how we can use a list to store all of our departments in one variable called lDepts. Note we are using an “l” as a variable prefix to denote the Depts variable is a list (see the “Whats in a Name?” sidebar in Step 2, “Using Variables”).

<CFSET lDepts="Marketing,Operations,Sales,Technology">


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint