Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default I need help with a formula.

I've subtracted two dates and now I want to do a IF statement. Do I have to
convert to numeric to do that? It's not bringing up correct values. At this
time H7 equals :45. How do I get the formula to work?

=IF(H7<=35,"On Target","Not on Target")
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 860
Default I need help with a formula.

Hi QA,

Your question isn't entirely clear, however I think
this is what you are looking for.

=IF((H7*24*60)<=35,"On Target","Not on Target")

The extra brackets are not necessary.
Time is stored as a fraction of a day
so multiplying by 24 takes it to hours
then multiplying by 60 takes it to minutes.
Of course you can just multiply by 1440

HTH
Martin

"QA Queen" <QA wrote in message
...
I've subtracted two dates and now I want to do a IF statement. Do I have
to
convert to numeric to do that? It's not bringing up correct values. At
this
time H7 equals :45. How do I get the formula to work?

=IF(H7<=35,"On Target","Not on Target")



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default I need help with a formula.

One other guess ..

If H7 would contain textstrings
such as the one you posted, ie: ":45"
where you want to compare the number after the colon

then you could try in say, I7:
=IF(TRIM(H7)="","",IF(RIGHT(H7,LEN(H7)-SEARCH(":",H7))+0<=35,"On
Target","Not on Target"))
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"QA Queen" wrote:
I've subtracted two dates and now I want to do a IF statement. Do I have to
convert to numeric to do that? It's not bringing up correct values. At this
time H7 equals :45. How do I get the formula to work?

=IF(H7<=35,"On Target","Not on Target")

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 04:33 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"