Use: <@IF "<@CALC '<@CURROW> % 2'> = 0"> do this
<@ELSE> do that </@IF Works fine and for 100% regards Daniel Richardy ----- Original Message ----- From: "WebDude" <[EMAIL PROTECTED]> To: <[email protected]> Sent: Thursday, March 22, 2007 9:01 PM Subject: RE: Witango-Talk: Determining even or odd > Sounds good... I've already got it in place. > > > WebDude > > > -----Original Message----- > From: Ben Johansen [mailto:[EMAIL PROTECTED] > Sent: Thursday, March 22, 2007 2:45 PM > To: [email protected] > Subject: Re: Witango-Talk: Determining even or odd > > I agree, > > i have seen 4 represented as 3.9999999999999999 > > Ben > > On Mar 22, 2007, at 12:39 PM, John McGowan wrote: > > I'd make sure you use The "mod" method that Bill showed using the % > operator. > > Dividing by 2 and looking for a "." is kind of a hack... if Witango ever > decides to output decimal numbers for integers for some reason, your code is > going to break. > > 8 / 2 = 4.0 > > On 3/22/07, WebDude <[EMAIL PROTECTED]> wrote: >> >> >> duh :-/ >> >> Thanks >> >> >> ________________________________ >> >> >> >> >> >> Yup. >> >> >> >> <@If "<@calc expr='<@currow>/2'> contains '.'"> .. This value is odd >> </@if> >> >> >> >> =) >> >> >> >> -S >> >> >> >> >> Shane Pearlman >> >> 831.345.7033 >> >> S&P, Inc. >> >> >> >> >> >> ________________________________ >> >> >> From: WebDude [mailto:[EMAIL PROTECTED] >> Sent: Thursday, March 22, 2007 11:56 AM >> To: [email protected] >> Subject: Witango-Talk: Determining even or odd >> >> >> >> >> In a <@ROWS> >> >> >> <@CURROW> >> >> >> </@ROWS> >> >> >> >> >> >> Is there an easy way to detrmine if the number is even or odd So I can >> do an <@IFEQUAL> statement? >> >> >> >> >> >> ie. <@IFEQUAL <@CURROW> "ODD">Do This<@ELSE>Do That</@IF> >> >> >> >> >> >> Thanks >> >> >> >> >> >> >> >> >> WebDude >> >> >> ______________________________________________________________________ >> __ >> TO UNSUBSCRIBE: Go to >> http://www.witango.com/developer/maillist.taf >> >> ______________________________________________________________________ >> __ >> TO UNSUBSCRIBE: Go to >> http://www.witango.com/developer/maillist.taf >> >> >> ______________________________________________________________________ >> __ >> TO UNSUBSCRIBE: Go to >> http://www.witango.com/developer/maillist.taf >> >> > > > -- > John McGowan > Seven A C Consulting, Inc. > ________________________________________________________________________ > TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf > > ________________________________________________________________________ > TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf > ________________________________________________________________________ > TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf > > > ________________________________________________________________________ TO UNSUBSCRIBE: Go to http://www.witango.com/developer/maillist.taf
