WRAPROWS function

This function wraps the provided row or column of cells by rows after a specified number of elements to form a new array.

Sample Usage

WRAPROWS(A1:E1, 2): A WRAPROWS function that wraps the range with 2 values per row.

WRAPROWS(A1:E1, 2, “No value”): A WRAPROWS function that wraps the range with 2 values per row and fills the extra cells with “No value.”

Syntax

WRAPROWS(range, wrap_count, [pad_with])

  • range: The range to wrap.
  • wrap_count: The maximum number of cells for each row. If the value isn’t a whole number, it’s rounded down to the nearest whole number.
  • [pad_with]: The value with which to fill the extra cells in the range. By default, the WRAPROWS function fills the extra cells with #N/A.

Examples

Wrap simple data with WRAPROWS

Example data:

 

A

B

C

D

E

1

A

B

C

D

E

Example: Input this formula in G1: =WRAPROWS(A1:E1, 2)

Result:

 

G

H

1

A

B

2

C

D

3

E

#N/A

Make a Copy

Wrap data with “No value” as pad with WRAPROWS

Example data:

 

A

B

C

D

E

1

A

B

C

D

E

Example: Input this formula in G1: =WRAPROWS(A1:E1, 2, "No value")

Result:

 

G

H

1

A

B

2

C

D

3

E

No value

Make a Copy

Related functions

  • WRAPCOLS function: This function wraps the provided row or column of cells by columns after a specified number of elements to form a new array.
Was this helpful?
How can we improve it?
Search
Clear search
Close search
Google apps
Main menu
Search Help Center
true
true
false
true
true
35
false
false