Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

help with IFF and MOD functions!

Status
Not open for further replies.

NeoTurtle

Programmer
Aug 25, 2000
38
US
Hi everyone. I've been up all night trying to figure something out. I could get it working if I could just understand what this means in plain English:

<TR BGCOLOR=&quot;#IIF(((CurrentRow MOD 2) IS 0),DE('FFFFFF'),DE('EEEECC'))#&quot;>

I tried looking all my help references which turned out to be helpLESS. MOD returns the remainder of integer1 in MOD(integer1, integer2)??
Does that mean something like:
3 divided by 2 is 1.5
so the value returned is .5????
Now my book says that a Similar CF Expression would be:
integer1 MOD
If my expample of 3 divided by 2 is 1.5 is correct, then how does it know what to divide by in something like:
3 MOD

Or could it be that I've been up too long???? Geez . . . most people are waking up at this time!

Thanks in advance,
-NeoTurtle
[sig][/sig]
 
This is a simple way of alternating the background color of each row in a table. The mod function when used with the divisor 2 always returns a 1 or a 0. Using it this way changes the background color of every other row in the table. [sig][/sig]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top