<cfset columns = 3>
<table>
<cfloop index="thisRow" from="1" to="#myquery.recordcount#"
step="#columns#">
    <cfloop index="thisColumn" from="1" to="#columns#">
        <cfif thisColumn eq 1><tr></thisColumn>
        <td><cfoutput>#myquery.myinfo[thisRow+thisColumn-1]#</cfoutput></td>
        <cfif thisColumn eq columns></tr></cfif>
    </cfloop>
</cfloop>
</table>

The above doesn't take into account when you get to your last row and you
have less than 3 records left in the query.

But as Phil says, this comes up pretty regularly, so have a look in the
archives for other solutions :
http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4

Stephen

----- Original Message ----- 
From: "Kris Pilles" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Friday, July 11, 2003 2:57 PM
Subject: Output values in table Vertically


> Does anyone have some code that displays values in a table Vertically
> rather then the noraml horizantal output....
>
> Any help would be apprecited.
>
> Thanks
>
> KP
>
> Kris Pilles
> Website Manager
> Western Suffolk BOCES
> 507 Deer Park Rd., Building C
> Phone: 631-549-4900 x 267
> E-mail: [EMAIL PROTECTED]
>
>
> 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4
Subscription: 
http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4
FAQ: http://www.thenetprofits.co.uk/coldfusion/faq

Get the mailserver that powers this list at 
http://www.coolfusion.com

                                Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4
                                

Reply via email to