> I am having trouble remembering the exact syntax when using 
> IIF.  I am 
> outputting some records into a table format and I want to 
> start a new row 
> after every 3rd record.

I don't think this is suitable for IIF.  The reason being is that there are
3 possibilities for the rowcount... Ie start, end, middle.  IIF would be
fine if there were only 2 cells, as it's a yes or no type condition.

The way I would do it is that you have the loop, so start the first tr and
then after every 3, put in </tr><tr>

Easier in a cfif:

<tr>
<cfoutput query="test">
<cfif test.rowcount mod 3 eq 0>
        </tr><tr>
</cfif>
<td>
<!--- output the data into td's --->
</td>
</cfoutput>
</tr>

Make sense?

> Like so:
> 
> <cfoutput query="test">
>       <tr><td>record 1</td><td>record 2</td><td>record 3</td></tr>
>       <tr><td>record 4</td><td>record 5</td> and so on.... </cfoutput>
> 
> How do I setup the iif to do this?
> 
> Thanks
> 
> Dave
> 
> 
> -- 
> ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
> 
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: 
> [EMAIL PROTECTED] For human help, e-mail: 
> [EMAIL PROTECTED]
> 
> 
> 




-- 
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/

To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]

Reply via email to