Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 17
Default Question about using SUM with a date criteria

Hello,

I'm using the following array formula (Thank you again Macropod!) to add
Sick/Vacation/Personal leave hours (as simple numbers) in cells that also
contain text:

=SUM(IF(ISERROR(VALUE(LEFT(B1:B4,FIND("
",B1:B4)-1))),0,VALUE(LEFT(B1:B4,FIND(" ",B1:B4)-1))))

Is there a way to add a date criteria to this formula so that it will only
add those hours as of the current date? In the spreadsheet, Column A
contains dates.

Any help is appreciated.

Thanks,

Mike

  #2   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 4,393
Default Question about using SUM with a date criteria

You should tell us more about what your data looks like
Meanwhile look into SUMPRODUCT
http://www.xldynamic.com/source/xld.SUMPRODUCT.html
http://mcgimpsey.com/excel/formulae/doubleneg.html

--
Bernard V Liengme
Microsoft Excel MVP
www.stfx.ca/people/bliengme
remove caps from email

"Michael Slater" wrote in message
...
Hello,

I'm using the following array formula (Thank you again Macropod!) to add
Sick/Vacation/Personal leave hours (as simple numbers) in cells that also
contain text:

=SUM(IF(ISERROR(VALUE(LEFT(B1:B4,FIND("
",B1:B4)-1))),0,VALUE(LEFT(B1:B4,FIND(" ",B1:B4)-1))))

Is there a way to add a date criteria to this formula so that it will only
add those hours as of the current date? In the spreadsheet, Column A
contains dates.

Any help is appreciated.

Thanks,

Mike



  #3   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 287
Default Question about using SUM with a date criteria

Try

=SUM(IF(A1:A4=TODAY(),LEFT(0&B1:B4,FIND(" ",B1:B4&" "))+0))

confirmed with CTRL+SHIFT+ENTER

"Bernard Liengme" wrote:

You should tell us more about what your data looks like
Meanwhile look into SUMPRODUCT
http://www.xldynamic.com/source/xld.SUMPRODUCT.html
http://mcgimpsey.com/excel/formulae/doubleneg.html

--
Bernard V Liengme
Microsoft Excel MVP
www.stfx.ca/people/bliengme
remove caps from email

"Michael Slater" wrote in message
...
Hello,

I'm using the following array formula (Thank you again Macropod!) to add
Sick/Vacation/Personal leave hours (as simple numbers) in cells that also
contain text:

=SUM(IF(ISERROR(VALUE(LEFT(B1:B4,FIND("
",B1:B4)-1))),0,VALUE(LEFT(B1:B4,FIND(" ",B1:B4)-1))))

Is there a way to add a date criteria to this formula so that it will only
add those hours as of the current date? In the spreadsheet, Column A
contains dates.

Any help is appreciated.

Thanks,

Mike




  #4   Report Post  
Posted to microsoft.public.excel.newusers
external usenet poster
 
Posts: 2
Default Question about using SUM with a date criteria

Thank you for your suggestions! Daddylonglegs, I was not able to get your
formula to work, however, I did figure out how to modify the original formula
I was using:

=SUM(IF(ISERROR(VALUE(LEFT(B1:B4,FIND("
",B1:B4)-1))),0,VALUE(LEFT(B1:B4,FIND(" ",B1:B4)-1))))

Modification:

=SUM(IF(A1:A4<=TODAY(),IF(ISERROR(VALUE(LEFT(B1:B4 ,FIND("
",B1:B4)-1))),0,VALUE(LEFT(B1:B4,FIND(" ",B1:B4)-1)))))

Again, Thanks for all your help!

Mike



"daddylonglegs" wrote:

Try

=SUM(IF(A1:A4=TODAY(),LEFT(0&B1:B4,FIND(" ",B1:B4&" "))+0))

confirmed with CTRL+SHIFT+ENTER

"Bernard Liengme" wrote:

You should tell us more about what your data looks like
Meanwhile look into SUMPRODUCT
http://www.xldynamic.com/source/xld.SUMPRODUCT.html
http://mcgimpsey.com/excel/formulae/doubleneg.html

--
Bernard V Liengme
Microsoft Excel MVP
www.stfx.ca/people/bliengme
remove caps from email

"Michael Slater" wrote in message
...
Hello,

I'm using the following array formula (Thank you again Macropod!) to add
Sick/Vacation/Personal leave hours (as simple numbers) in cells that also
contain text:

=SUM(IF(ISERROR(VALUE(LEFT(B1:B4,FIND("
",B1:B4)-1))),0,VALUE(LEFT(B1:B4,FIND(" ",B1:B4)-1))))

Is there a way to add a date criteria to this formula so that it will only
add those hours as of the current date? In the spreadsheet, Column A
contains dates.

Any help is appreciated.

Thanks,

Mike




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


Similar Threads
Thread Thread Starter Forum Replies Last Post
=DMIN(database,field,criteria) question about criteria Dummy Excel Discussion (Misc queries) 2 April 16th 07 08:02 PM
DCOUNTA Complex Criteria Question Elliot Colbert Excel Worksheet Functions 5 June 19th 06 10:57 PM
Criteria based sum question masik Excel Discussion (Misc queries) 6 June 7th 06 07:30 AM
SUMIF Question Criteria Dave Excel Worksheet Functions 3 February 8th 06 12:48 PM
query criteria question Dcbrown428 Excel Discussion (Misc queries) 1 November 18th 05 05:20 PM


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

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

About Us

"It's about Microsoft Excel"