Date in IF Statement

JTL9161

Well-known Member
Joined
Aug 29, 2012
Messages
565
Office Version
  1. 365
Platform
  1. Windows
I searched around but could not find my answer so I thought I would try here. It's probably something simple.

I am copying data from a spreadsheet listing to an invoice bill on another tab within the same spreadsheet.


Spreadsheet (Sheet1) has dates and payments. I am saying in the on the Invoice Tab (Sheet2)

=IF(Sheet1!A1="","",A1) which is saying if cell A1 does not have a date then leave it blank on the Invoice tab

but if cell A1 does have a date then show that date on the Invoice Tab.

When its blank it shows blank but when the date say 5/1/2016 the date shown on the Invoice tab is 1/0/1900

and I have the cell formatted for DATE mm/dd/yyyy.

Suggestions?

Thanks,
James
 

Excel Facts

Create a Pivot Table on a Map
If your data has zip codes, postal codes, or city names, select the data and use Insert, 3D Map. (Found to right of chart icons).
It doesn't look like you have a date in cell A1 of the Invoice tab. Are you perhaps trying to do this?
=IF(Sheet1!A1="","",Sheet1!A1)
 
Upvote 0
The cell A1 may be TEXT.
Try coercing the data to a number by adding 0 =IF(Sheet1!A1="","",A1+0)
If there are non-printing characters, review information on Excel's Clean and Trim.

As Robert mentioned, ensure that you are referencing the correct cell
=IF(Sheet1!A1="","",Sheet1!A1)
 
Last edited:
Upvote 0
DOH! I knew I needed another set of eyes! Thanks.
 
Upvote 0

Forum statistics

Threads
1,213,563
Messages
6,114,329
Members
448,564
Latest member
ED38

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top