+ Reply to Thread
Results 1 to 4 of 4

IF Statement: After certain dates, retrieve several lines of text

  1. #1
    Registered User
    Join Date
    06-18-2014
    Location
    New York
    MS-Off Ver
    2013
    Posts
    11

    IF Statement: After certain dates, retrieve several lines of text

    [SOLVED by amromerodiaz]

    Hi there,

    I'm trying to create a formula that allows me to retrieve several lines of text after certain dates have passed. For instance:

    After Jan 1 - "Happy new year"
    After Feb 1 - "1 Month in"
    After March 1 - "Spring is on"

    Now it's Jul 23. I want to see the cell show: Happy new year & 1 Month in & Spring is on

    The formula that I have so far is below. The problem is that it only retrieves happy new year. How can I change it to see multiple entries?

    (A1 = 23 Jul, B1 = Jan 1, B2 = Feb 1, B3 = Mar 1)

    =IF(A1>B1,"Happy new year",IF(A1>B2,"1 Month in",IF(A1>B3,"Spring is on","")))

    Thanks for your help!
    Last edited by c.mayer; 07-23-2014 at 10:49 AM.

  2. #2
    Registered User
    Join Date
    05-19-2014
    Location
    Berlin, Germany
    MS-Off Ver
    Excel 2013
    Posts
    8

    Re: IF Statement: After certain dates, retrieve several lines of text

    Hello,

    Try this formula

    =IF(A1>B1,"Happy new year")&" "&IF(A1>B2,"1 Month in")&" "&IF(A1>B3,"Spring is on","")

    Regards,

    Alvaro

  3. #3
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: IF Statement: After certain dates, retrieve several lines of text

    Attach a sample workbook. Make sure there is just enough data to demonstrate your need. Include a BEFORE sheet and an AFTER sheet in the workbook if needed to show the process you're trying to complete or automate. Make sure your desired results are shown, mock them up manually if necessary.

    Remember to desensitize the data.

    Click on GO ADVANCED and use the paperclip icon to open the upload window.

    View Pic
    Regards
    sktneer


    Treat people the way you want to be treated. Talk to people the way you want to be talked to.
    Respect is earned NOT given.

  4. #4
    Registered User
    Join Date
    06-18-2014
    Location
    New York
    MS-Off Ver
    2013
    Posts
    11

    Re: IF Statement: After certain dates, retrieve several lines of text

    That's really clever! Thanks Alvaro!

  5. #5
    Forum Guru sktneer's Avatar
    Join Date
    04-30-2011
    Location
    Kanpur, India
    MS-Off Ver
    Office 365
    Posts
    9,649

    Re: IF Statement: After certain dates, retrieve several lines of text

    If that takes care of your question, please mark your thread as Solved by selecting Thread Tools (just above your first post) --> Mark thread as solved.
    Moreover you may also click on * (star) to Add Reputation to those who have put their time and efforts to help you in this forum. This is another way to say thanks to them.

+ 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] Macro to Delete useless lines, rearrange by dates and skip lines between different days.
    By Tmc2159 in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 06-12-2012, 02:15 PM
  2. Retrieve value between two dates
    By kostas.markou in forum Excel General
    Replies: 1
    Last Post: 08-17-2011, 01:33 AM
  3. Retrieve External Data via SQL Statement
    By bgillock in forum Excel General
    Replies: 2
    Last Post: 06-13-2007, 09:34 AM
  4. [SOLVED] Tricky If statement involving dates and text - I'm stumped!!!
    By mike_vr in forum Excel General
    Replies: 2
    Last Post: 06-26-2006, 12:25 PM
  5. need to retrieve dates from lookup
    By MRT in forum Excel General
    Replies: 5
    Last Post: 03-27-2006, 12:25 AM

Tags for this Thread

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