---
title: "setPathComponentCells(_:)"
framework: appkit
role: symbol
role_heading: Instance Method
path: "appkit/nspathcontrol/setpathcomponentcells(_:)"
---

# setPathComponentCells(_:)

Sets the array of NSPathComponentCell objects currently being displayed.

## Declaration

```swift
func setPathComponentCells(_ cells: [NSPathComponentCell])
```

## Parameters

- `cells`: An array of NSPathComponentCell objects.

## Discussion

Discussion Each item in the array must be an instance of NSPathComponentCell or a subclass thereof. You cannot set this value to nil, but you can set it to an empty array using, for example, [NSArray array].

## See Also

### Managing Path Components

- [clickedPathComponentCell()](appkit/nspathcontrol/clickedpathcomponentcell().md)
- [pathComponentCells()](appkit/nspathcontrol/pathcomponentcells().md)
