Wrap a Five-Column Excel Table Into Fixed Row Blocks
Question details
Create fixed-height display blocks from a five-column Excel table without separating the values that belong to the same record.

- Product
- Microsoft Excel for Microsoft 365
- Device & OS
- not provided
- Scenario
- The user wants to divide filtered table records into groups with a fixed number of rows for display or printing on landscape-oriented pages.
- Observed behavior
- A one-dimensional wrapping approach can split individual fields apart instead of retaining each complete five-column record.
Confirm that the source data is a consistent two-dimensional range or Excel Table, with one complete record per row. Decide the number of records to show in each block, such as four rows per block.
Wrap the filtered two-dimensional array with a custom Microsoft 365 LAMBDA
Use this method when the workbook already contains the Snapλ and WrapRows2Dλ named functions and you want a formula-based result that preserves complete rows.
Do not flatten the source table into a single vector before wrapping it. Pass the full filtered array to a two-dimensional wrapping LAMBDA so all five columns in each record remain together.
Select the top-left cell where the first row block should spill, then enter the formula in the Formula Bar.
Use =WrapRows2Dλ(DROP(Snapλ(T_Data,"Biology"),,1),4,""). Replace "Biology" with the required subject or filter value, and replace 4 with the number of source rows required in each block.
Go to Formulas > Name Manager and confirm that Snapλ and WrapRows2Dλ are defined in the workbook. These are custom named LAMBDA functions, not standard Excel function names.
Select the output range, then go to Page Layout > Orientation > Landscape. Use Page Layout > Breaks > Insert Page Break if each block must print on a separate page.

Create row blocks with Index, Block, and RowInBlock helper columns
Use this reliable method when custom LAMBDA functions are unavailable or when each group must be filtered, copied, or printed separately.
Group Complete Table Rows Into Printable Blocks in WPS Spreadsheets
WPS Spreadsheets can use helper formulas to assign each complete table row to a fixed-size block, then filter and print each block in landscape orientation. This approach keeps multi-column records together and is easy to adapt when the block size changes.
- 1. Open the source workbook: In WPS Spreadsheets, open the Excel workbook and verify that each record occupies one row across all five columns.
- 2. Add an Index column: Insert a new column named Index and enter a sequential number for each data row, starting with 1.
- 3. Create the Block formula: Insert a Block column and enter =QUOTIENT(IndexCell-1,4)+1, replacing IndexCell with the first Index cell and 4 with your required rows per block.
- 4. Filter one block at a time: Select the table, choose Data > Filter, and use the Block column filter to display the required group of complete records.
- 5. Print in landscape orientation: Choose Page Layout > Orientation > Landscape, then use Print Preview to print the filtered block before selecting the next Block value.

Frequently Asked Questions
Why does WRAPROWS separate values from the same Excel record?
WRAPROWS is designed for a one-dimensional array. If a five-column table is converted into one vector first, the function counts individual cells rather than complete source rows, so fields can be placed in different blocks.
How do I change the number of records in each Excel block?
Change the rows-per-block value in the formula. For example, replace 4 in =QUOTIENT([@Index]-1,4)+1 and =MOD([@Index]-1,4)+1 with 6 to create six-record blocks.
Can I print each row block on a separate landscape page?
Yes. Filter the Block column to one value, then select Page Layout > Orientation > Landscape and print the filtered rows. You can also use Page Layout > Breaks > Insert Page Break when blocks appear in one output range.
Are Snapλ and WrapRows2Dλ built-in Excel functions?
No. They are custom named LAMBDA functions that must already be defined in Formulas > Name Manager. If the workbook does not include them, use helper columns or create equivalent named LAMBDA functions.




