+ Reply to Thread
Results 1 to 5 of 5

if the 15th of the month falls between two dates, calculate, otherwise 0

  1. #1
    Registered User
    Join Date
    04-01-2015
    Location
    Canberra, Australia
    MS-Off Ver
    2010
    Posts
    2

    Question if the 15th of the month falls between two dates, calculate, otherwise 0

    Hi,

    This is my first post and I hope someone is able to help. I have a spreadsheet that tracks my banking expenditure by fortnight. However, there are some transactions that happen automatically on a particular day each month.

    Each column heading is the start date of each fortnight.

    What I am trying to do is for a cell to have a formula in it that determines if a particular day of the month (say the 15th) falls between two column heading dates and, if so, carries out a transaction, otherwise returns zero.

    I've seen some formulas that use the =IF(AND... functions, but I've not been able to find out a way to change it to fit my needs.

    Hope someone can help.

    Cheers

    Hurleyinoz

  2. #2
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    24,704

    Re: if the 15th of the month falls between two dates, calculate, otherwise 0

    It would help if you attached a sample workbook, then we could see which columns you are using. The FAQ describes how to.

    Pete

  3. #3
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: if the 15th of the month falls between two dates, calculate, otherwise 0

    Here's one way, assuming fortnight start date in B1

    =IF(SUM(0+(DAY(B1+{0,1,2,3,4,5,6,7,8,9,10,11,12,13})=15)),"yes","no")

    you can copy the formula across
    Audere est facere

  4. #4
    Registered User
    Join Date
    04-01-2015
    Location
    Canberra, Australia
    MS-Off Ver
    2010
    Posts
    2

    Re: if the 15th of the month falls between two dates, calculate, otherwise 0

    Quote Originally Posted by daddylonglegs View Post
    Here's one way, assuming fortnight start date in B1

    =IF(SUM(0+(DAY(B1+{0,1,2,3,4,5,6,7,8,9,10,11,12,13})=15)),"yes","no")

    you can copy the formula across
    Thanks for this info Daddylonglegs

    Is there a way to refer to the 0-13 numbers as a series rather than having them all listed like that?

  5. #5
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    2016
    Posts
    14,675

    Re: if the 15th of the month falls between two dates, calculate, otherwise 0

    Here's an altenative

    =IF(SUMPRODUCT(0+(DAY(B1+ROW(INDIRECT("1:14"))-1)=15)),"yes","no")

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 3
    Last Post: 01-03-2015, 03:33 PM
  2. Rounding Dates up to the 15th or the last day of the month
    By karenbr in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 12-12-2011, 04:52 PM
  3. Replies: 5
    Last Post: 07-09-2011, 03:51 AM
  4. Replies: 2
    Last Post: 09-16-2009, 06:50 PM
  5. count no. of dates in a column that falls on certain month & year
    By RawSugar in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 10-20-2005, 06:05 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1