A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Excel » Worksheet Functions
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

formula help



 
 
Thread Tools Display Modes
  #1  
Old June 18th, 2004, 06:14 AM
external usenet poster
 
Posts: n/a
Default formula help

i need help =if(K740,K7-40,0)
now k7 is going to equal =sum(C7:J7)
but if K5 .00 then K5 needs to be subtracted from K7

i need help righting this formula

  #2  
Old June 18th, 2004, 07:13 AM
Norman Harker
external usenet poster
 
Posts: n/a
Default formula help

Hi!

If I'm interpreting you correctly:

K7 formula becomes:
=IF(K50,SUM(C7:J7)-K5,SUM(C7:J7))

Leaving your original formula at:
=if(K740,K7-40,0)

Or merging the two formulas:
=IF((IF(K50,SUM(C7:J7)-K5,SUM(C7:J7)))40,(IF(K50,SUM(C7:J7)-K5,SUM(C7:J7)
))-40,0)

But rather than:
=if(K740,K7-40,0)
Use:
=MAX(K7-40,0)

And merging you get:
=MAX(IF(K50,SUM(C7:J7)-K5,SUM(C7:J7))-40,0)
--
--
Regards
Norman Harker MVP (Excel)
Sydney, Australia

Excel and Word Function Lists (Classifications, Syntax and Arguments)
available free to good homes.

wrote in message
...
i need help =if(K740,K7-40,0)
now k7 is going to equal =sum(C7:J7)
but if K5 .00 then K5 needs to be subtracted from K7

i need help righting this formula



  #3  
Old June 18th, 2004, 08:04 AM
external usenet poster
 
Posts: n/a
Default formula help


-----Original Message-----
i need help =if(K740,K7-40,0)
now k7 is going to equal =sum(C7:J7)
but if K5 .00 then K5 needs to be subtracted from K7

i need help righting this formula

.
that didn't seem to work. i messed up i gave you the

wrong info sorry.

k5 is =SUM(C5:J5)
K7 is =sum(C7:J7)
K8 is =if(K740,K7-40,0)


if any number greater than .00 is in K5 that number needs
to be subtracted from K8 if no number is in k5 than k8 can
equal any number above 40 from k7.

example: if K5 has a value of 6, and then k7 has a value
47 after adding C7:J7. i would then need to be able to
subtract k5 the value of 6 from K7 value of 47.
  #4  
Old June 18th, 2004, 08:59 AM
Harlan Grove
external usenet poster
 
Posts: n/a
Default formula help

"Norman Harker" wrote...
....
But rather than:
=if(K740,K7-40,0)
Use:
=MAX(K7-40,0)

And merging you get:
=MAX(IF(K50,SUM(C7:J7)-K5,SUM(C7:J7))-40,0)

....

Follow that logic to its ultimate conclusion.

=MAX(0,SUM(C7:J7)-MAX(0,K5)-40)


  #5  
Old June 18th, 2004, 09:24 AM
Harry Bo
external usenet poster
 
Posts: n/a
Default formula help

Not sure about this but try:

=IF(AND(K7-K5=40,K5=0),K7-K5,0)

if I understand you right, or tell me otherwise

Harry

" wrote:


-----Original Message-----
i need help =if(K740,K7-40,0)
now k7 is going to equal =sum(C7:J7)
but if K5 .00 then K5 needs to be subtracted from K7

i need help righting this formula

.
that didn't seem to work. i messed up i gave you the

wrong info sorry.

k5 is =SUM(C5:J5)
K7 is =sum(C7:J7)
K8 is =if(K740,K7-40,0)


if any number greater than .00 is in K5 that number needs
to be subtracted from K8 if no number is in k5 than k8 can
equal any number above 40 from k7.

example: if K5 has a value of 6, and then k7 has a value
47 after adding C7:J7. i would then need to be able to
subtract k5 the value of 6 from K7 value of 47.

  #6  
Old June 18th, 2004, 12:14 PM
external usenet poster
 
Posts: n/a
Default formula help

that isn't working. this might help if i explain better
what i am trying to complete.

k5 is =SUM(C5:J5) this cell is for sicktime or vacation

K7 is =sum(C7:J7) total hours worked with k5 included

K8 is =if(K740,K7-40,0) is overtime but if the employee
has any vacation time used in k5 that needs to be
subtracted before any overtime will appear. If no hours
are used for vacation in k5 then i want k8 to equal
anything over 40 from my total in k7.

Thank you for your Help.



-----Original Message-----
Not sure about this but try:

=IF(AND(K7-K5=40,K5=0),K7-K5,0)

if I understand you right, or tell me otherwise

Harry

" wrote:


-----Original Message-----
i need help =if(K740,K7-40,0)
now k7 is going to equal =sum(C7:J7)
but if K5 .00 then K5 needs to be subtracted from K7

i need help righting this formula

.
that didn't seem to work. i messed up i gave you the

wrong info sorry.

k5 is =SUM(C5:J5)
K7 is =sum(C7:J7)
K8 is =if(K740,K7-40,0)


if any number greater than .00 is in K5 that number

needs
to be subtracted from K8 if no number is in k5 than k8

can
equal any number above 40 from k7.

example: if K5 has a value of 6, and then k7 has a

value
47 after adding C7:J7. i would then need to be able to
subtract k5 the value of 6 from K7 value of 47.

.

  #7  
Old June 18th, 2004, 12:25 PM
Andy B
external usenet poster
 
Posts: n/a
Default formula help

Hi

Try:
=MAX(K7-K5-40,0)

--
Andy.


wrote in message
...
that isn't working. this might help if i explain better
what i am trying to complete.

k5 is =SUM(C5:J5) this cell is for sicktime or vacation

K7 is =sum(C7:J7) total hours worked with k5 included

K8 is =if(K740,K7-40,0) is overtime but if the employee
has any vacation time used in k5 that needs to be
subtracted before any overtime will appear. If no hours
are used for vacation in k5 then i want k8 to equal
anything over 40 from my total in k7.

Thank you for your Help.



-----Original Message-----
Not sure about this but try:

=IF(AND(K7-K5=40,K5=0),K7-K5,0)

if I understand you right, or tell me otherwise

Harry

" wrote:


-----Original Message-----
i need help =if(K740,K7-40,0)
now k7 is going to equal =sum(C7:J7)
but if K5 .00 then K5 needs to be subtracted from K7

i need help righting this formula

.
that didn't seem to work. i messed up i gave you the
wrong info sorry.

k5 is =SUM(C5:J5)
K7 is =sum(C7:J7)
K8 is =if(K740,K7-40,0)


if any number greater than .00 is in K5 that number

needs
to be subtracted from K8 if no number is in k5 than k8

can
equal any number above 40 from k7.

example: if K5 has a value of 6, and then k7 has a

value
47 after adding C7:J7. i would then need to be able to
subtract k5 the value of 6 from K7 value of 47.

.



  #8  
Old June 18th, 2004, 01:34 PM
external usenet poster
 
Posts: n/a
Default formula help

Thank you that seems to work. Thanks tons!!!
-----Original Message-----
Hi

Try:
=MAX(K7-K5-40,0)

--
Andy.


wrote in message
...
that isn't working. this might help if i explain better
what i am trying to complete.

k5 is =SUM(C5:J5) this cell is for sicktime or vacation

K7 is =sum(C7:J7) total hours worked with k5 included

K8 is =if(K740,K7-40,0) is overtime but if the

employee
has any vacation time used in k5 that needs to be
subtracted before any overtime will appear. If no hours
are used for vacation in k5 then i want k8 to equal
anything over 40 from my total in k7.

Thank you for your Help.



-----Original Message-----
Not sure about this but try:

=IF(AND(K7-K5=40,K5=0),K7-K5,0)

if I understand you right, or tell me otherwise

Harry

" wrote:


-----Original Message-----
i need help =if(K740,K7-40,0)
now k7 is going to equal =sum(C7:J7)
but if K5 .00 then K5 needs to be subtracted from

K7

i need help righting this formula

.
that didn't seem to work. i messed up i gave you

the
wrong info sorry.

k5 is =SUM(C5:J5)
K7 is =sum(C7:J7)
K8 is =if(K740,K7-40,0)


if any number greater than .00 is in K5 that number

needs
to be subtracted from K8 if no number is in k5 than

k8
can
equal any number above 40 from k7.

example: if K5 has a value of 6, and then k7 has a

value
47 after adding C7:J7. i would then need to be able

to
subtract k5 the value of 6 from K7 value of 47.

.



.

 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 07:05 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.