Share via

Spreadsheet date problem

Anonymous
2020-07-30T20:29:47+00:00

I have a spreadsheet with 35 rows. 2 columns.

I have an IF formula in cell 36 =IF(B2="","",A2&": "&B2&".") So, if there is no data in Cell B2, my formula cell remains blank. If i have something in cell B2, it puts A2 in front of B2 and provides an answer.

Im using this for many cells and it's been fine for years now. I now changed the FORMAT of B2 to reflect the date differently than how i type it. i type 7-30-2020 and formatting changes it to Thursday, July 30, 2020 for me. Great! But in my formula cell (A36) it no longer works.

Before it would read "(A2) Date is (B2) 7-30-2020" now that i formatted that date cell it's reading "(A2) Date is (B2) 44043". Why isn't it reporting the correct version of the date?

Thanks

Microsoft 365 and Office | Excel | For home | Windows

Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.

0 comments No comments

Answer accepted by question author

Anonymous
2020-08-04T05:28:25+00:00

Dear Chuck,

Excel treats dates as Number while formatting is only for visual display to us.

What you are encountering is due to change in format of the cell to Date specific function.

Please try below formula. I hope it works out for you.

=IF(B2="","",A2&": "&TEXT(B2,"dddd")&", "&TEXT(B2,"mmm")&" "&DAY(B2)&", "&(YEAR(B2)))

Additionally it will be safe to use the formula given above as it will make outcome independent of format of source cell :):):)

Was this answer helpful?

0 comments No comments

5 additional answers

Sort by: Most helpful
  1. Anonymous
    2020-07-31T13:36:33+00:00

    so here is the exact formula i'm using. i'm doing this for 36 different cells at once, and again it all works. but when i request a date it doesnt work.

    i made a new sheet with just one formula. still broken

    cell A9 is =IF(B2="","",A2&": "&B2&".")

    Cell A2 = "date"

    Cell B2 = "7-31-2020"

    Cell A9 should return "date: 7-31-2020"

    I then formatted B2 to change date format to read day, month, date, year so when i type in quickly 7-31-2020 it READS "Friday, July 31, 2020" in hopes that cell B2 would return "Date: Friday, July 31, 2020" but it doesn't.  it's returning "Date: 44043"

    Was this answer helpful?

    0 comments No comments
  2. Anonymous
    2020-07-31T13:23:29+00:00

    Thanks for the reply Jeovany! unfortunately that doesn't work. I tried that already. No amount of formatting changes the answer. the source cell is formatted, and answer cell is formatted. answer is still 44043 and not the date as intended.

    Here's a new question. Is there a format within the formula? like because of the formula, the answer is defaulting to "general format" setting or something? not sure if im explaining it correctly but it's just another thought. 

    Thanks again

    Was this answer helpful?

    0 comments No comments
  3. Anonymous
    2020-07-31T00:39:51+00:00

    Hi Chuck

    Please, change the cell formatting in cell A36 to "Long Date" to convert 44043 to a date value displayed as "Friday 31 July 2020"

    I hope this helps you

    Regards

    Was this answer helpful?

    0 comments No comments
  4. Deleted

    This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.


    Comments have been turned off. Learn more