View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.misc
Tim[_6_] Tim[_6_] is offline
external usenet poster
 
Posts: 10
Default help with mod function

Problem is K2 can be any where from 1 or 2 (equaling J2) to 179 to 400+
The final working number I need is the value of J2....assuming K2 is less
than 180.
If K2 is greater than 180...then I want the mod function to give me the
normal remainder
With the new below formula...If K2 is say 127...the function will erase the
0, 1, or 2 in J2...and insert the K2 value of 127
....which I am trying to prevent from happening ?

Maybe what I want can't be done...hope I am clear on the above...?

Can the mode function ignore the value (make no change) in cell J2...if the
value of the adjoining K2 is less than 180...
But still perform the mod function...giving me the remainder...if the value
of K2 is = or greater than 180 ?


"www.exciter.gr: Custom Excel Applications!" wrote in
message oups.com...
Sorry didnt understand youw question well. I agree with others, you
should use formula:

=IF(K2=180,MOD(K2,180),K2)

Best

http://www.exciter.gr
Custom Excel Applications and Functions!


On Oct 31, 9:32 pm, "Tim" wrote:
This is really close...however...in the adjacent column where the mod
function is run...there are existing values

If K2 is = to or greater than 180...I want the mod value returned when
the
function is run in J2
If K2 is less than 180...I want no action...the existing value in J2
(usually 0,1, or 2) is to be left alone

The below formulas replaces the 0,1, or 2 in J2 with an empty cell...is
there a way to leave the J2 value alone if K2 is less than 180 ?

Thanks, Tim

"www.exciter.gr:Custom Excel Applications!" wrote in
ooglegroups.com...



You should add one more parameter in your IF formula:


=IF(K2=180,MOD(K2,180),"")


this formula check if K2=180 and if it is, it returns the MOD's
result, if it not, it returns blank.


http://www.exciter.gr
Custom Excel Applications and Functions!


On Oct 31, 8:06 pm, "Tim" wrote:
I have a problem with the mod function...I need to make it conditional
on
the related adjacent cell...here's what I have


=IF(K2=180,MOD(K2,180))


What I need is if K2 is equal to or greater than 180 then execute the
mod
function in the appropriate adjacent cell
If K2 is less than 180 then do not execute the mode function in the
adjacent
cell...leave the exiting number , if any, alone


The above executes the mod function ok if equal or greater than
180...but
if
less than 180...it's returning a false statement ?


I'm sure this is simple but I can't come up with changes that give the
above
desired results.


Thanks, Tim- Hide quoted text -


- Show quoted text -