Function Problems

WPS Spreadsheets: How to Return the Second, Third, and Later Nonblank Cells

Bushra ParveenBushra Parveen Nov 13, 2026 869 views

Question details

The user needs a formula that skips blank cells and returns the second, third, fourth, and subsequent nonblank values from a horizontal range, such as a form response row.

How to Return the Second, Third, and Later Nonblank Cells in WPS Spreadsheets
Product
WPS Spreadsheets
Device & OS
not provided
Scenario
The user is working with a horizontal row of form responses that contains scattered blanks and wants to list only the filled responses in order.
Observed behavior
The goal is to extract successive nonblank values instead of the full range, so blanks are ignored and values are returned in left-to-right order.
Before you start

Identify the exact horizontal range that contains the blanks, such as 'Form Responses 1'!$L$2:$AU$2. In WPS Spreadsheets versions without dynamic arrays, be ready to enter the formula with Ctrl+Shift+Enter.

Solution 1Recommended

Return the second, third, and later nonblank cells with INDEX, SMALL, and IF

Use this array formula when you need to pull successive nonblank values from a horizontal range and blanks are scattered irregularly.

The formula uses IF to create an array of relative column numbers for cells that are not empty, SMALL to pick the nth smallest matching position, and INDEX to return the value at that position. As you copy the formula right, COLUMN(A$1) increases to 2, 3, 4 and returns the second, third, fourth, and later nonblank values.

1
Select the first output cell

Click the cell where you want the first extracted nonblank value, such as B2.

2
Enter the INDEX-SMALL-IF formula

Type =INDEX('Form Responses 1'!$L$2:$AU$2,SMALL(IF('Form Responses 1'!$L$2:$AU$2<>"",COLUMN('Form Responses 1'!$L$2:$AU$2)-11),COLUMN(A$1))). Replace the sheet name and range with your actual data range.

3
Confirm as an array formula if needed

In WPS Spreadsheets or Excel versions before Microsoft 365/Excel 2021, press Ctrl+Shift+Enter instead of Enter so the formula is evaluated as an array formula.

4
Copy the formula across

Drag the fill handle to the right to return the second, third, fourth, and subsequent nonblank values in order.

Return the second, third, and later nonblank cells with INDEX, SMALL, and IF
Formula returns nonblank values in order: The COLUMN(A$1) argument increments as you copy right, so SMALL returns the 1st, 2nd, 3rd, and later matching positions.
WPS Spreadsheets solution

Return second, third, and later nonblank cells with WPS Spreadsheets

Enter the INDEX, SMALL, and IF array formula in WPS Spreadsheets and copy it across to extract successive nonblank values from any horizontal range.

  1. 1. Open your workbook in WPS Spreadsheets: Launch WPS Office, open the workbook with the horizontal range, and click the sheet that contains your form responses.
  2. 2. Select the output cell and enter the formula: Click the first output cell and type the INDEX-SMALL-IF formula, replacing 'Form Responses 1'!$L$2:$AU$2 with your actual range.
  3. 3. Confirm with Ctrl+Shift+Enter if required: If your WPS Spreadsheets version requires legacy array entry, press Ctrl+Shift+Enter. In newer versions, Enter may be enough.
  4. 4. Copy the formula across to return later values: Drag the fill handle to the right so COLUMN(A$1) increments from A$1 to B$1, C$1, and so on.
Uses the same INDEX, SMALL, and IF logic you already know from ExcelCompatible with .xlsx, .xls, and .csv files for easy Microsoft Excel migrationFree, lightweight, and includes a familiar ribbon interface for formula entryLets you confirm legacy array formulas quickly with Ctrl+Shift+Enter
microsoft office alternative - wps office

Frequently Asked Questions

Why does the formula subtract 11 from the COLUMN result?

The sample range starts at column L, which is column 12. Subtracting 11 converts absolute column numbers 12, 13, 14, and so on into relative positions 1, 2, 3 for INDEX. If your range starts in a different column, replace 11 with COLUMN(first cell)-1.

Do I need to press Ctrl+Shift+Enter in WPS Spreadsheets?

In WPS Spreadsheets and Excel versions before Microsoft 365 or Excel 2021, press Ctrl+Shift+Enter to enter the formula as an array formula. In newer versions that support dynamic arrays, pressing Enter may be sufficient.

Can I adapt this formula for a vertical range?

Yes. Replace COLUMN with ROW and adjust the subtraction to the starting row. For example, use ROW(range)-start_row+1 instead of COLUMN(range)-11, and copy the formula down instead of across.

What can I do if the formula returns #NUM! after all nonblank values are returned?

Wrap the formula in IFERROR, such as =IFERROR(INDEX(...),""), to return a blank cell when no further matching position exists. Make sure the range reference and column adjustment match your data.