Index Loop

 <cfloop index = "parameter_name"           from = "beginning_value"           to = "ending_value"           step = "increment">           ...           HTML or CFML code to execute  ... 

Conditional Loop

 <cfloop condition = "expression"> 

Query Loop

 <cfloop query = "query_name"           startRow = "row_num"           endRow = "row_num"> 

List/File Loop

 <cfloop index = "index_name"           list = "list_items"           delimiterS = "item_delimiter"> 

COM Collection/Structure Loop

 <cfloop collection = #variable#           item = "item"> 


Looping is a programming technique that repeats a set of instructions or displays output repeatedly until one or more conditions are met. An Index loop repeats for a number of times that is determined by a numeric value. An Index loop is also known as a For loop.


index (Required)

The current value that the loop is on; it is set by ColdFusion increments or decrements by the step value until it equals to the final value.

from (Required)

Beginning value of index.

to (Required)

Ending value of index.

step (Optional)

Default: 1; the step by which to increment or decrement the index value.

condition (Required for conditional loop)

Condition that controls the loop.

query (Required for query loop)

Query that controls the loop.

startRow (Optional)

First row of the query that looped over.

endRow (Optional)

Last row of the query that is looped over.

index (Required in an index of List/File loop)

In a list loop, the variable to receive next list element.

list (Required in a List/File loop)

A list, variable, or filename that contains a list to loop over.

delimiters (Optional)

Character(s) that separates items in the list.

Inside ColdFusion MX
Inside Coldfusion MX
ISBN: 0735713049
EAN: 2147483647
Year: 2005
Pages: 579 © 2008-2017.
If you may any questions please contact us: