+ Reply to Thread
Results 1 to 5 of 5

If Date Insert Value

  1. #1
    Registered User
    Join Date
    04-20-2015
    Location
    PA, USA
    MS-Off Ver
    O365 2019
    Posts
    2

    If Date Insert Value

    Hello,

    I am trying to find the formula that I would need to input a value if the date is the 15th business day of the month (so if 15th is Saturday, Monday's date would be where I want the value inserted)

    Ex: Cell A1 is the date in cell B1 if that date in A1 is the 15th (or closest business day) insert 21, if it is not 0

    Thank you for helping!

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,094

    Re: If Date Insert Value

    I think I follow your requirement...


    =IF(A1=WORKDAY(EOMONTH(A1,-1)+1,15),21,0)
    Attached Files Attached Files
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: Lá fhéile Pádraig sona dhaoibh

  3. #3
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    81,090

    Re: If Date Insert Value

    Welcome to the forum.

    Try this:

    =IF(NETWORKDAYS.INTL(EOMONTH(A1,-1)+1,A1)=15,21,0)
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  4. #4
    Registered User
    Join Date
    04-20-2015
    Location
    PA, USA
    MS-Off Ver
    O365 2019
    Posts
    2

    Re: If Date Insert Value

    Thank you both! but neither worked for me :-(

    Glenn I downloaded the book and if I enter 3/15/21 it does not insert the "21" value, it only does it for 3/21/21?

    AliGW it returned a zero for me each time?

    What I am trying to do is a payment calendar - so I am trying to get it to populate the payment that comes in on the 15th (or next business day) of each month.

  5. #5
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    81,090

    Re: If Date Insert Value

    Then provide a sample workbook showing us what you want. Mock it up manually.

+ 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. [SOLVED] Insert default date into blank cells in date column
    By deleter in forum Excel General
    Replies: 9
    Last Post: 08-01-2017, 11:36 AM
  2. [SOLVED] Insert static date automatically on pasting large amount of date
    By Toro- in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-21-2016, 08:11 AM
  3. [SOLVED] Function/formula to compare and insert todays date or yesterdays date
    By TC922 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-17-2013, 05:28 AM
  4. Complex VBA problem auto insert date and time, auto insert comment, etc.
    By rojashan in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 06-29-2013, 09:40 PM
  5. [SOLVED] Insert 'From Date - To Date into pivot table/chart as a title
    By Smudge.Smith in forum Excel Charting & Pivots
    Replies: 2
    Last Post: 04-09-2013, 10:45 AM
  6. Insert tomorrow's date unless Friday. If Friday, insert Monday's date.
    By Cboeree in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 10-13-2012, 01:21 AM
  7. Replies: 4
    Last Post: 07-27-2012, 04:10 AM

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