+ Reply to Thread
Results 1 to 3 of 3

"Expired" and "Live" dates.

  1. #1
    Registered User
    Join Date
    03-18-2010
    Location
    London, England
    MS-Off Ver
    Excel 2003
    Posts
    2

    Smile "Expired" and "Live" dates.

    Hi all,

    Is there a way of having the words "Expired" or "Live" appear in a cell adjoining a date?
    The word "Live" would appear for dates in the future and the word "Expired" would appear for dates in the past.
    And, if possible, I'd like to have the word "Expired" appear in black and the word "Live" appear in red.

    Many thanks.

  2. #2
    Forum Contributor
    Join Date
    03-12-2009
    Location
    Calgary, Canada
    MS-Off Ver
    Excel 365
    Posts
    236

    Re: "Expired" and "Live" dates.

    put a formula in the cell you want the words to appear such as:

    Please Login or Register  to view this content.
    this assumes that the date you are testing is in cell A2

    to get the color of the words to change, just use conditional formatting using one rule would work, just select the column and go to conditional formatting (under the format menu) and type Live into the first rule and change the format to red the way you want. Press okay, and if it is not working, go back into the conditional format and make sure that the rule appears as ="Live", the problem can be that excel likes to add its own quotes so if you were to enter ="Live" first excel would convert it to =""Live"" which doesn't work, so just go back in and remove the second set of quotes.

    Hope this helps.
    If you can't figure out how a formula works, try stepping through it using "Evaluate Formula" in the Formula Auditing menu item in the tools menu!

    If you want to see where your code went wrong, try stepping through it by clicking in the code and pressing F8 and watch as the magic happens!


    If you are happy with any of the results, please add to the contributor's reputation by clicking the star icon.

  3. #3
    Registered User
    Join Date
    03-18-2010
    Location
    London, England
    MS-Off Ver
    Excel 2003
    Posts
    2

    Re: "Expired" and "Live" dates.

    Everstrivin
    That works perfectly. Thank you very much indeed.

    - Paul

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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