Function Problems

Check Whether an Excel Date Falls in April and Return a Cell Value

Phi Hung VoPhi Hung Vo Nov 18, 2026 868 views

Question details

Check whether a date falls in April and return a value from another cell.

Check Whether an Excel Date Falls in April and Return a Cell Value
Product
Microsoft Excel
Device & OS
not provided
Scenario
A worksheet has a date in D4 and a value in F4 that should be returned when the date is in April.
Observed behavior
The formula should return F4 for an April date and either zero or a blank for other months.
Before you start

Check that D4 contains a valid Excel date rather than unrecognized text, and identify the cell containing the value you want to return. Replace D4 and F4 in the formula if your data is in different cells.

Solution 1Recommended

Use IF and MONTH to Return a Value for an April Date

Use this formula to test the month regardless of how the date is displayed.

1
Select the result cell

Click an empty cell where you want the result to appear.

2
Enter the formula

Type =IF(MONTH(D4)=4,F4,0) in the cell or formula bar, then press Enter. The formula returns F4 if D4 is in April; otherwise, it returns zero.

3
Use a blank if preferred

To show a blank instead of zero for other months, enter =IF(MONTH(D4)=4,F4,"") in the result cell.

4
Apply it to other rows

Select the formula cell and drag its fill handle down to check the dates and return values in subsequent rows.

Use IF and MONTH to Return a Value for an April Date
The year is not checked: MONTH(D4)=4 matches April in any year. A date stored as unrecognized text can cause an error, so convert it to a valid Excel date first.
WPS Spreadsheet

Check April Dates with a Formula in WPS Spreadsheet

Use the same IF and MONTH formula in WPS Spreadsheet to check a date and return a value from another cell.

  1. 1. Open the worksheet: Open WPS Spreadsheet and use Open to select your Excel workbook.
  2. 2. Check the source cells: Find the date in D4 and the value to return in F4, or note the corresponding cells in your worksheet.
  3. 3. Enter the formula: Click an empty result cell, enter =IF(MONTH(D4)=4,F4,0), and press Enter.
  4. 4. Extend and save: Drag the result cell's fill handle down for additional rows, then select Save to save the workbook.
Check April dates without relying on the displayed date formatOpen and save Microsoft Excel XLSX filesFill the formula down to evaluate multiple rowsUse familiar spreadsheet functions and controls
microsoft office alternative - wps office

Frequently Asked Questions

How do I return a blank instead of zero for dates outside April?

Enter =IF(MONTH(D4)=4,F4,"") in the result cell. The final pair of quotation marks makes the formula return an empty string.

Does the formula work with different date display formats?

Yes. MONTH reads the underlying date value in D4, so the display format does not need to show the word April. The cell must contain a valid date.

Will the formula match April in any year?

Yes. MONTH(D4)=4 checks only the month. To check a specific year as well, use a formula such as =IF(AND(MONTH(D4)=4,YEAR(D4)=2026),F4,0).

Why does the formula return an error?

Check whether D4 contains a valid date rather than unrecognized text. Also check your regional settings: some Excel installations use semicolons instead of commas to separate formula arguments.