Skip to content

Latest commit

 

History

History
46 lines (29 loc) · 1.22 KB

Excel.PivotCell.RowItems.md

File metadata and controls

46 lines (29 loc) · 1.22 KB
title keywords f1_keywords api_name ms.assetid ms.date ms.localizationpriority
PivotCell.RowItems property (Excel)
vbaxl10.chm692078
vbaxl10.chm692078
Excel.PivotCell.RowItems
4833f772-9abd-a2fa-e3f0-e86f54caf05e
05/04/2019
medium

PivotCell.RowItems property (Excel)

Returns a PivotItemList collection that corresponds to the items on the category axis that represent the selected cell.

Syntax

expression.RowItems

expression A variable that represents a PivotCell object.

Example

This example determines if the data item in cell B5 is under the Inventory item in the first row field and notifies the user. The example assumes that a PivotTable exists on the active worksheet, and that column B of the worksheet contains a row item of the PivotTable.

Sub CheckRowItems() 
 
 ' Determine if there is a match between the item and row field. 
 If Application.Range("B5").PivotCell.RowItems.Item(1) = "Inventory" Then 
 MsgBox "Cell B5 is a member of the 'Inventory' row field. 
 Else 
 MsgBox "Cell B5 is not a member of the 'Inventory' row field. 
 End If 
 
End Sub

[!includeSupport and feedback]