This only works in CFMX. But you could use another function for numeric values (like val())
Pascal > -----Original Message----- > From: Barney Boisvert [mailto:[EMAIL PROTECTED] > Sent: 02 November 2004 19:54 > To: CF-Talk > Subject: Re: mod command to alter row color > > Get rid of that evaluate, it's unneeded: > > <style> > tr.alt1 { background-color: #fff; } > tr.alt0 { background-color: #ffc; } > </style> > <cfoutput> > <table> > <cfloop query="myQuery"> > <tr class="alt#currentRow MOD 2#"> > ... > </tr> > </cfloop> > </table> > </cfoutput> > > On Tue, 2 Nov 2004 11:42:55 -0700, Jim McAtee <[EMAIL PROTECTED]> > wrote: > > I generally start by setting up two CSS classes, with similar names > ending > > in 0/1. > > > > <style type="text/css"> > > tr.rowstyle1 { > > background-color: #ffffff; > > } > > tr.rowstyle0 { > > background-color: #e0e0e0; > > } > > </style> > > <cfoutput> > > <cfloop query="somequery"> > > <tr class="rowstyle#Evaluate('somequery.currentrow mod 2')#"> > > ... > > </tr> > > </cfloop> > > </cfoutput> > > > > Or you can use IIf() if not using CSS: > > > > <cfoutput> > > <cfloop query="somequery"> > > <tr background="#IIf(somequery.currentrow mod 2, DE('##ffffff'), > > DE('##e0e0e0'))#"> > > ... > > </tr> > > </cfloop> > > </cfoutput> > > > > > -- > Barney Boisvert > [EMAIL PROTECTED] > 360.319.6145 > http://www.barneyb.com/blog/ > > I currently have 0 GMail invites for the taking > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Purchase from House of Fusion, a Macromedia Authorized Affiliate and support the CF community. http://www.houseoffusion.com/banners/view.cfm?bannerid=37 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:183184 Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4 Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

